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

Cannot assign to read only property'exports'of object' <Object> #1216

Open
lmxdawn opened this issue May 8, 2019 · 2 comments
Open

Cannot assign to read only property'exports'of object' <Object> #1216

lmxdawn opened this issue May 8, 2019 · 2 comments

Comments

@lmxdawn
Copy link

lmxdawn commented May 8, 2019

JS generated using pbjs

Running error, error message

Cannot assign to read only property'exports'of object' <Object>'

@lmxdawn
Copy link
Author

lmxdawn commented May 8, 2019

Change module.exports = $root; from proto.js to export default $root;

The problem was solved.

@zlk89
Copy link

zlk89 commented Jun 18, 2019

You should pass -w es6 in your pbjs command to generate es6 style export

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