Vigia

Nâng cấp entities từ 7.x lên 8.x

So sánh API công khai của entities 7.0.1 và 8.1.0, được tính tự động từ kiểu TypeScript. Chữ ký thay đổi là thay đổi có thể không tương thích, không phải điều chắc chắn.

Tóm tắt

Đường dẫn import bị xóa0
Export bị xóa9
Chữ ký thay đổi7
Thành viên lớp hoặc interface bị xóa0
Thành viên lớp hoặc interface thay đổi0
Mới bị ngừng hỗ trợ1
Thay đổi yêu cầu (engines, phụ thuộc peer)1
Export mới2

Export bị xóa

importexportkindTrước
entitiesdecodeHTML4function(htmlString: string, mode?: DecodingMode | undefined): string
entitiesdecodeHTML5function(htmlString: string, mode?: DecodingMode | undefined): string
entitiesencodeHTML4function(input: string): string
entitiesencodeHTML5function(input: string): string
entitiesdecodeStrictfunction(input: string, options?: DecodingOptions | EntityLevel | undefined): string
entitiesdecodeHTML4Strictfunction(htmlString: string): string
entitiesdecodeHTML5Strictfunction(htmlString: string): string
entities/decodefromCodePointvariable(...codePoints: number[]): string
entities/decodedecodeCodePointfunction(codePoint: number): string

Chữ ký thay đổi

exportTrướcSau
entities · escapeText(data: string): string(data: string): string
entities · escapeUTF8(data: string): string(data: string): string
entities · escapeAttribute(data: string): string(data: string): string
entities/escape · escapeText(data: string): string(data: string): string
entities/escape · escapeUTF8(data: string): string(data: string): string
entities/escape · getCodePoint(c: string, index: number): number(input: string, index: number): number
entities/escape · escapeAttribute(data: string): string(data: string): string

Thành viên lớp hoặc interface bị xóa

Không phát hiện.

Thành viên lớp hoặc interface thay đổi

Không phát hiện.

Mới bị ngừng hỗ trợ

export@deprecated
entities/escape · getCodePointUse `String.prototype.codePointAt` directly instead; this export will be removed in the next major.

Thay đổi yêu cầu (engines, phụ thuộc peer)

TrướcSau
engines.node>=0.12>=20.19.0
Export mới (2)
importexportkind
entities/decodereplaceCodePointXMLfunction
entities/escapexmlEncodeRegexvariable

Câu hỏi thường gặp

Nâng cấp entities từ 7 lên 8 có những thay đổi không tương thích nào?

Giữa entities 7.0.1 và 8.1.0, Vigia tìm thấy 9 export bị xóa, 7 chữ ký thay đổi và 0 thành viên lớp hoặc interface bị xóa hay thay đổi.

Những gì bị ngừng hỗ trợ trong entities 8?

1 export hoặc thành viên mới bị đánh dấu ngừng hỗ trợ trong entities 8.1.0.

Dành cho tác tử

GET https://vigia.coredls.cloud/v1/packages/npm/entities/upgrade?from=7.0.1&to=8.1.0