-
Notifications
You must be signed in to change notification settings - Fork 157
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 SDK support #1862
JS SDK support #1862
Conversation
maxhr
commented
Aug 2, 2022
- Major refactor
- JS SDK
- CLI user prompts
- JS SDK - CLI user prompts
Since it will be the main way to create JS contract, let's add instructions here: near/near-sdk-js#145 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fact that CI does not work for some people in our org is annoying. Why is this happening?
@volovyk-s it still breaks on M1 because of workspaces-rs. Is that what you mean? |
@maxhr I think @volovyk-s means that actions are not being triggered, and that's because the PR comes from another repo. Maybe we should migrate the branch here. |
Yes, forks don't trigger actions on the original. I don't have permissions to push here. |
I meant what @gagdiez said. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. A couple non-blocking comments:
- Testing - If I read correctly, there is no test in place right now to test recommending WSL for Windows environments. Maybe good to have something like this in place. It would also be nice for the e2e tests to have a summary view once they have run, they produce a lot of output on the terminal atm which is hard to follow.
- Dependency versioning management - Every template comes with dependencies and each their own versions. I believe it would make the repo easier to maintain if these versions would be specified in one file and these values would be extracted when dApp is created by user.
- Config management / maintainability - Similar to the point above, I notice the supported languages/frameworks are specified multiple times throughout multiple files in the repo, this can get painful to manage as we add support for more languages and frameworks in the future. I would suggest using a config file and specifying these in the config file and have the rest of the repo read this file.
Also, npm run test
fails for the js
tests for me in my ubuntu machine.
src/user-input.ts
Outdated
const optionsAreValid = hasAllOptions | ||
&& ['react', 'vanilla', 'none'].includes(frontend) | ||
&& ['js', 'rust', 'assemblyscript'].includes(contract) | ||
&& ['js', 'rust'].includes(tests); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've seen definitions like these here and in types.ts
(and probably still other parts), would it be perhaps better to define these in a separate config.json
file or similar for the entire project once and fetch those definitions from that file instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed
@volovyk-s this is ready to be merged |
@gagdiez ok |