-
Notifications
You must be signed in to change notification settings - Fork 409
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
Split init into init and build #216
Conversation
24dac77
to
617b996
Compare
looking great so far @csmoe thanks for taking this on! this will def require some docs updates! i can get you a review by tomorrow, but in the meantime- if you want to add docs that would be great! |
@mgattozzi will rebase soon. |
88f868a
to
7ce7a2a
Compare
hey @csmoe - sorry it's taken me so long to review this. so just to be sure i understand, the current code- when you run anyways, i think for the most part this is ready to merge (needs a rebase cuz i merged #211 but i'm happy to handle that for you) but we still have some questions about workflow/UX. i'm meeting with @alexcrichton and @fitzgen to talk more about the user flow later today, so i can update after that meeting- but if you have thoughts, please share! |
@ashleygwilliams I copied the workflow from your comment there:
I was also puzzled by the repeated init-steps in
I love this. |
fcbb1f0
to
b8ce2b4
Compare
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.
Works great for me! thanks
@@ -1,9 +1,9 @@ | |||
# wasm-pack init | |||
# wasm-pack init(Deprecated) |
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.
nit: space before (
/// this flag will disable generating this TypeScript file. | ||
pub disable_dts: bool, | ||
|
||
#[structopt(long = "target", short = "t", default_value = "browser")] |
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.
btw browser
is not accurate. ESM will be soon available in Nodejs, which isn't a browser.
The correct targets are:
- CJS (commonjs)
- ESM (ECMAScript modules)
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.
ESM will be soon available in Nodejs, which isn't a browser.
so should I leave a FIXME note here or change it to ESM
right now?
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.
leave whatever the current behavior is, and let's file an issue to update.
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 won't block on this, but considering it's in the readme it's a bit more visual so I think we should fix this doc now. Anyways, you did a great job @csmoe :D
@@ -29,9 +29,10 @@ visiting that repo! | |||
|
|||
## 🎙️ Commands | |||
|
|||
- [`init`](docs/init.md): [**Deprecated**] Initialize an npm wasm pkg from a rustwasm crate | |||
- [`build`](docs/build.md): Generate an npm wasm pkg from a rustwasm crate | |||
- [`init`](docs/init.md): Generate an npm wasm pkg from a rustwasm crate |
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 like this line wasn't removed despite having added the deprecated tag
@ashleygwilliams Sorry for missing your comment there since I was nearly done at that time.