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

Error: Unexpected character ']' when adding an attribute that contains ']' #30

Open
tannerlyons opened this issue Feb 10, 2016 · 2 comments

Comments

@tannerlyons
Copy link

Here's the simplest repro:

listItem = put(document.body, "div");
put(listItem, "input[type=text][title=[surrounded by brackets]]");

https://jsfiddle.net/tannermeans/utjtgaa3/7/

Seems like these characters should be allowed - or is there another way to do this?

@kriszyp
Copy link
Owner

kriszyp commented Feb 10, 2016

You can do:

put(listItem, "input[type=text][title=$]", "[surrounded by brackets]")

But I think I see where the parsing error is occurring.

@tannerlyons
Copy link
Author

Ahh thanks for the quick reply and alternate method!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants