diff --git a/globals.html b/globals.html index 46ac25b..2e24639 100644 --- a/globals.html +++ b/globals.html @@ -981,25 +981,44 @@ img { max-width: 100%; }

The src folder is analyzed and documentation is automatically generated using typedoc.

yarn docs
 
-

This command generates API documentation for your library in HTML format.

+

This command generates API documentation for your library in HTML format and opens it in a browser.

Since types are tracked by Typescript, there's no need to indicate types in JSDoc format. For more information, see the typedoc documentation.

+

To generate and publish your documentation to GitHub Pages use the following command:

+
yarn docs:publish
+
+

Once published, your documentation should be available at the proper GitHub Pages URL for your repo. See this repo's GitHub Pages for an example.

typedoc documentation example

For more advanced documentation generation, you can provide your own typedoc theme, or build your own documentation using the JSON typedoc export:

yarn docs:json
 
-

Generate/update changelog & release

+

Generate/update changelog & tag release

This project is tooled for Conventional Changelog to make managing releases easier. See the standard-version documentation for more information on the workflow, or CHANGELOG.md for an example.

# bump package.json version, update CHANGELOG.md, git tag the release
+yarn changelog
+
+

One-step publish preparation script

+

Bringing together many of the steps above, this repo includes a one-step release command.

+
# Standard release
 yarn release
 # Release without bumping package.json version
-yarn release -- --first-release
+yarn changelog -- --first-release
 # PGP sign the release
-yarn release -- --sign
+yarn changelog -- --sign
 
+

This command runs:

+ +

When the script finishes, it will log the final command needed to push the release commit to the repo and publish the package on the npm registry:

+
git push --follow-tags origin master; npm publish
+

Look over the release if you'd like, then execute the command to publish everything.

All package scripts

-

You can run the info script for information on each available package script.

+

You can run the info script for information on each script intended to be individually run.

yarn run info
 
   info:
@@ -1009,27 +1028,25 @@ yarn release -- --sign
   lint:
     Lint all typescript source files
   unit:
-    Run unit tests
+    Build the library and run unit tests
   test:
-    Lint and test the library
+    Lint, build, and test the library
   watch:
     Watch source files, rebuild library on changes, rerun relevant tests
-  watch:build:
-    Watch source files, rebuild library on changes
-  watch:unit:
-    Watch the build, rerun relevant tests on changes
   cov:
     Run tests, generate the HTML coverage report, and open it in a browser
-  html-coverage:
-    Output HTML test coverage report
-  send-coverage:
-    Output lcov test coverage report and send it to codecov
   docs:
-    Generate API documentation and open it in a browser
+    Generate HTML API documentation and open it in a browser
+  docs:publish:
+    Generate HTML API documentation and push it to GitHub Pages
   docs:json:
     Generate API documentation in typedoc JSON format
   release:
     Bump package.json version, update CHANGELOG.md, tag a release
+  reset:
+    Delete all untracked files and reset the repo to the last commit
+  publish:
+    Reset, build, test, publish docs, and prepare release (a one-step publish process)
 

Notes

Multiple builds (main, module, and browser)

The src of typescript-starter is compiled into three separate builds: main, module, and browser. The main build is configured to use the CommonJS module system, while the module build uses the new ES6 module system. The browser build contains two bundles, an ES6 module (the preferred export) and a CommonJS bundle (primarily used for testing).

@@ -1073,7 +1090,7 @@ yarn release -- --sign
  • @@ -1106,7 +1123,7 @@ asyncABC().then(console.log);
  • @@ -1153,7 +1170,7 @@ asyncABC().then(console.log);
  • @@ -1194,7 +1211,7 @@ asyncABC().then(console.log);
  • diff --git a/index.html b/index.html index dafade5..d4833c1 100644 --- a/index.html +++ b/index.html @@ -981,25 +981,44 @@ img { max-width: 100%; }

    The src folder is analyzed and documentation is automatically generated using typedoc.

    yarn docs
     
    -

    This command generates API documentation for your library in HTML format.

    +

    This command generates API documentation for your library in HTML format and opens it in a browser.

    Since types are tracked by Typescript, there's no need to indicate types in JSDoc format. For more information, see the typedoc documentation.

    +

    To generate and publish your documentation to GitHub Pages use the following command:

    +
    yarn docs:publish
    +
    +

    Once published, your documentation should be available at the proper GitHub Pages URL for your repo. See this repo's GitHub Pages for an example.

    typedoc documentation example

    For more advanced documentation generation, you can provide your own typedoc theme, or build your own documentation using the JSON typedoc export:

    yarn docs:json
     
    -

    Generate/update changelog & release

    +

    Generate/update changelog & tag release

    This project is tooled for Conventional Changelog to make managing releases easier. See the standard-version documentation for more information on the workflow, or CHANGELOG.md for an example.

    # bump package.json version, update CHANGELOG.md, git tag the release
    +yarn changelog
    +
    +

    One-step publish preparation script

    +

    Bringing together many of the steps above, this repo includes a one-step release command.

    +
    # Standard release
     yarn release
     # Release without bumping package.json version
    -yarn release -- --first-release
    +yarn changelog -- --first-release
     # PGP sign the release
    -yarn release -- --sign
    +yarn changelog -- --sign
     
    +

    This command runs:

    + +

    When the script finishes, it will log the final command needed to push the release commit to the repo and publish the package on the npm registry:

    +
    git push --follow-tags origin master; npm publish
    +

    Look over the release if you'd like, then execute the command to publish everything.

    All package scripts

    -

    You can run the info script for information on each available package script.

    +

    You can run the info script for information on each script intended to be individually run.

    yarn run info
     
       info:
    @@ -1009,27 +1028,25 @@ yarn release -- --sign
       lint:
         Lint all typescript source files
       unit:
    -    Run unit tests
    +    Build the library and run unit tests
       test:
    -    Lint and test the library
    +    Lint, build, and test the library
       watch:
         Watch source files, rebuild library on changes, rerun relevant tests
    -  watch:build:
    -    Watch source files, rebuild library on changes
    -  watch:unit:
    -    Watch the build, rerun relevant tests on changes
       cov:
         Run tests, generate the HTML coverage report, and open it in a browser
    -  html-coverage:
    -    Output HTML test coverage report
    -  send-coverage:
    -    Output lcov test coverage report and send it to codecov
       docs:
    -    Generate API documentation and open it in a browser
    +    Generate HTML API documentation and open it in a browser
    +  docs:publish:
    +    Generate HTML API documentation and push it to GitHub Pages
       docs:json:
         Generate API documentation in typedoc JSON format
       release:
         Bump package.json version, update CHANGELOG.md, tag a release
    +  reset:
    +    Delete all untracked files and reset the repo to the last commit
    +  publish:
    +    Reset, build, test, publish docs, and prepare release (a one-step publish process)
     

    Notes

    Multiple builds (main, module, and browser)

    The src of typescript-starter is compiled into three separate builds: main, module, and browser. The main build is configured to use the CommonJS module system, while the module build uses the new ES6 module system. The browser build contains two bundles, an ES6 module (the preferred export) and a CommonJS bundle (primarily used for testing).

    @@ -1074,7 +1091,7 @@ yarn release -- --sign
  • @@ -1107,7 +1124,7 @@ asyncABC().then(console.log);
  • @@ -1154,7 +1171,7 @@ asyncABC().then(console.log);
  • @@ -1195,7 +1212,7 @@ asyncABC().then(console.log);