String.prototype.trimEnd
es10,function
trimEnd() Phương thức xóa khoảng trắng từ đầu chuỗi và trả về một chuỗi mới. Có nghĩa là trimEnd() xoá những ký tự space bên phải mà không làm thay đổi chuỗi gốc.
let pingan8787 = ' Hello pingan8787! ';
console.log(pingan8787); // " Hello pingan8787! ";
console.log(pingan8787.length); // 23;
console.log(pingan8787.trimEnd()); // " Hello pingan8787!";
console.log(pingan8787.trimEnd().length); // 20;
Có thể bạn đã miss một số snippets code
Object.keys và Object.getOwnPropertyNames
Object.keys và Object.getOwnPropertyNames
Optional chaining javascript
Optional chaining javascript
Object.fromEntries
Object.fromEntries Là một phương thức mới được giới thiệu trong ES10 được sử dụng để chuyển đổi từ list có dạng key và value thành những objects.
try/catch es10
An update for developer convience allows the use of try/catch without an explicit e Error reference in the catch call.
Async await in javascript
Async await in javascript