Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JS error when your data properties contain special characters, quotation marks, etc #173

Open
grantcopley opened this issue Jan 10, 2025 · 1 comment
Assignees
Labels
bug Something isn't working
Milestone

Comments

@grantcopley
Copy link
Collaborator

Because the HTML isn't being properly escaped, you'll see errors like this.

VM1057:1 Uncaught SyntaxError: Expected ',' or '}' after property value in JSON at position 264 (line 1 column 265)
    at JSON.parse (<anonymous>)
    at new Component (livewire.js?id=239a5c52:4435:30)
    at initComponent (livewire.js?id=239a5c52:4529:23)
    at livewire.js?id=239a5c52:8544:28
    at livewire.js?id=239a5c52:1855:60
    at livewire.js?id=239a5c52:882:43
    at Array.forEach (<anonymous>)
    at livewire.js?id=239a5c52:882:28
    at walk (livewire.js?id=239a5c52:805:7)
    at livewire.js?id=239a5c52:880:9
@grantcopley grantcopley added the bug Something isn't working label Jan 10, 2025
@grantcopley grantcopley added this to the v4.1 milestone Jan 10, 2025
@grantcopley grantcopley self-assigned this Jan 10, 2025
@grantcopley grantcopley modified the milestones: v4.1, 4.2 Feb 20, 2025
@linuxonrails
Copy link

@grantcopley please, could you give a simple example where this problem occurs? 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants