diff --git a/docs/src/commands/build.md b/docs/src/commands/build.md index 9b12922e..45410538 100644 --- a/docs/src/commands/build.md +++ b/docs/src/commands/build.md @@ -3,11 +3,7 @@ The `wasm-pack build` command creates the files necessary for JavaScript interoperability and for publishing a package to npm. This involves compiling your code to wasm and generating a pkg folder. This pkg folder will contain the -wasm binary, a JS wrapper file, your `README`, and a `package.json` file. - -The `pkg` directory is automatically `.gitignore`d by default, since it contains -build artifacts which are not intended to be checked into version -control.[0](#footnote-0) +wasm binary, a JS wrapper file, your `README`, and a `package.json` file.[0](#footnote-0) ## Path @@ -140,6 +136,5 @@ wasm-pack build examples/js-hello-world --mode no-install -- --offline
-0 If you need to include additional assets in the pkg -directory and your NPM package, we intend to have a solution for your use case -soon. [↩](#wasm-pack-build) +0 In contrast to previous releases, a `.gitignore` +file is no longer created in the `pkg` directory. [↩](#wasm-pack-build) diff --git a/src/command/utils.rs b/src/command/utils.rs index 509bc530..197d045a 100644 --- a/src/command/utils.rs +++ b/src/command/utils.rs @@ -39,7 +39,6 @@ fn find_manifest_from_cwd() -> Result { pub fn create_pkg_dir(out_dir: &Path) -> Result<()> { let _ = fs::remove_file(out_dir.join("package.json")); // Clean up package.json from previous runs fs::create_dir_all(&out_dir)?; - fs::write(out_dir.join(".gitignore"), "*")?; Ok(()) }