Skip to content

Commit

Permalink
chore(devtool): add compatibility for UTF character
Browse files Browse the repository at this point in the history
  • Loading branch information
linghaoSu committed May 15, 2023
1 parent 220bbe3 commit ff7c753
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vee-validate/src/devtools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ function getFieldNodeTags(
function encodeNodeId(form?: PrivateFormContext, stateOrField?: PathState | PrivateFieldContext): string {
const type = stateOrField ? ('path' in stateOrField ? 'pathState' : 'field') : 'form';
const fieldPath = stateOrField ? ('path' in stateOrField ? stateOrField?.path : unref(stateOrField?.name)) : '';
const idObject = { f: form?.formId, ff: fieldPath, type };
const idObject = { f: encodeURIComponent(`${form?.formId}`), ff: encodeURIComponent(fieldPath), type };

return btoa(JSON.stringify(idObject));
}
Expand Down

0 comments on commit ff7c753

Please sign in to comment.