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

how come the contents of the node_modules folder once installed differs from this repository's files? #12

Open
vesper8 opened this issue Dec 9, 2020 · 2 comments

Comments

@vesper8
Copy link

vesper8 commented Dec 9, 2020

I'm confused here, when I install your package via NPM the contents of the chessboard-element folder inside my node_modules folder has a bunch of .js files that are nowhere to be found in this repository

I decided to fork your package so I can immediately use my click-to-move PR and when I tried to reference my fork inside my package.json I end up with an error because those .js files are not present

But when I install your package then they are present

What voodoo magic is at play here? Is there a command that needs to be run to generate the .js files?

I would love to have more information so I can get my fork working

Many thanks

@vesper8
Copy link
Author

vesper8 commented Dec 9, 2020

I was able to get it working by going inside the node_modules/chessboard-element folder, running yarn and then yarn bundle

That still did not generate the js files inside node_modules/chessboard-element/src/lib

But at least it made my errors go away

Would still appreciate knowing why the .js files are missing from this repository but present in the node_modules/chessboard-element/src/lib/ folder

And I guess in the future if I make updates to my fork, then I should run the bundle command and commit this file too, right?

Thanks

@justinfagnani
Copy link
Owner

This project is written in TypeScript and the built JavaScript is published to npm. The difference between GitHub is expected and normal for compiled languages. You should only commit the source TypeScript files to git.

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