-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Access has been denied to resolve the property "img" because it is not an "own property" of its parent. #1648
Access has been denied to resolve the property "img" because it is not an "own property" of its parent. #1648
Comments
When I try to use the allow-prototype-access extension for handlebars in my express-handlebars application, I get a "Error: Module "handlebars" does not provide a view engine."
|
You are using app.engine('hbs', ... in one place and app.set('view engine', 'handlebars') in the other. Try using either Update: Sorry, no, this is not the problem. I have used this code in the same way. I have to test it. Update 2: I wasn't that wrong... The solution is to use |
I'll update the readme of the package. |
You mean I need to delete |
@xreider can you show me how you tried to make it work? Your code doesn't contain the |
The rest of your code looks good, as long as your files have the extension
|
You helped me a lot! Thank you very much! You made me believe in miracles. |
Nils, that fix worked for me, I appreciate the help. I am indeed using .handlebars as my extension type for my templates. Providing 'hbs' as an argument even when using .handelbars as your extension name when using just the express-handlebars was working (and is actually what the express-handlebars documentation states) but I guess when using this updated package the |
Thank for ur advice:) |
You helped me a lot! Thank you very much! |
Thanks a lot nknapp. Tell me, have we then prevent to possible create these security holes? |
If you allow your users to create templates and execute those templates in your Node.js server, then your users may be able to crash your machine, or possibly inject code (if there is a new way of doing so, the publicly known ways should still be impossible with this setting). |
Its working. Thanks brother |
Thank you very much, bro. You are the only person giving me the correct solution |
@nknapp thank you so much!! been stuck on this for longer than I would like to admit |
thank you so much !!!! |
Thank you so much, I needed help !!!!!!! after 10 hour It was solved. Thank a lot. |
Show de bola! Valeu! |
It helped me so much, you gave useful infirmation. Thank you!!! |
Hi, I'm also new to JS and handlebars and having trouble implementing the @handlebars/allow-prototype-access' package. Could you please help? This is my current code, I'm not sure how to implement the allow-prototype-access package into my existing app.engine.
|
Thanks @nknapp .... you just saved from a lot of headache |
thx you, brother! :) 👍🏻 |
thankyou it worked |
Hello! I am a new in Node.js
Please, help me to rewrite my code
I have this problem with express-handlebars and mongoose
I tried to solve this problem with this webpage
But I got "Cannot find module '@handlebars/allow-prototype-access'" warning
I am a new to rewrite it now, just help me, please!
index.js file
package.json file
The text was updated successfully, but these errors were encountered: