"; / ? : @ & = + $ , #", And do not encode. After encoding, it outputs the utf-8 form of the symbol, and adds% before each byte.
The difference between encodeURIComponent() and encodeURI() is that it is used to encode individual parts of the URL instead of encoding the entire URL.Therefore
"; / ? : @ & = + $ , #", These symbols that are not encoded in encodeURI() will all be encoded in encodeURIComponent().As for the specific encoding method, the two are the same.