docs: Update build docs and clarify instructions#438
Conversation
|  | ||
|
|
||
| **Note:** You don't have to worry about breaking the site when you submit a pull request!** This is because your change will not be merged to production immediately. A Plotly team member will first perform a code review on your pull request. | ||
| **Note:** You don't have to worry about breaking the site when you submit a pull request! This is because your change will not be merged to production immediately. A Plotly team member will first perform a code review on your pull request. |
There was a problem hiding this comment.
I think this goes without saying! 😅
| @@ -34,13 +34,13 @@ The easiest way to do this is to follow the `Edit this page on GitHub` link at t | |||
|
|
|||
|  | |||
There was a problem hiding this comment.
Might be worth refreshing this screenshot. The site looks outdated and it looks like the button itself has changed
|
|
||
| Making sure that a pull request passes every CI check is part of the code review process. | ||
|
|
||
| ## Search indices |
There was a problem hiding this comment.
We use indexes in ddk-dash-docs (see https://learn.microsoft.com/en-us/style-guide/a-z-word-list-term-collections/i/index-indexes-indices)
|
|
||
| You can browse the indices at https://www.algolia.com/apps/7EK9KHJW8M/explorer/browse/. | ||
|
|
||
| **When to update:** Run the appropriate `update_*_search` target whenever a new tutorial is added to the corresponding `_posts/` directory. The `schema` index should be updated when a new plotly.js version is released. |
There was a problem hiding this comment.
Should makes your intent unclear here. Are you asking users to update it, or are you saying it's an automated update?
There was a problem hiding this comment.
I'll reword it.
| When you run a `$ jekyll` you need to update any scss file as jekyll will automatically replace the styles.css file. e.g.: if you modify any scss file and save it, it will overwrite the file jekyll has produced. | ||
| It's a bit of a hassle to make concurrent updates to markup and scss. Any time you update an html/js file you'll have to run `bundle exec jekyll build` (or run `bundle exec jekyll serve` with Jekyll watching for changes). Jekyll's watch mode can be slow on this repo because of its size; building on demand is sometimes preferable. | ||
|
|
||
| When you run `bundle exec jekyll …`, Jekyll will regenerate `styles.css` — so if you modify any scss file and save it, Jekyll's output may overwrite your changes. Run `gulp build` again to regenerate the css after Jekyll runs. |
There was a problem hiding this comment.
| When you run `bundle exec jekyll …`, Jekyll will regenerate `styles.css` — so if you modify any scss file and save it, Jekyll's output may overwrite your changes. Run `gulp build` again to regenerate the css after Jekyll runs. | |
| When you run `bundle exec jekyll …`, Jekyll regenerates `styles.css` — so if you modify any scss file and save it, Jekyll's output may overwrite your changes. Run `gulp build` again to regenerate the css after Jekyll runs. |
| Generally it's best to work with two instances of terminal, one to use for anything related to `$ jekyll` and then another to keep the `$ gulp` task running. | ||
|
|
||
| 1. run `$ jekyll serve --config _config_dev.yml` to create a local server @ http://localhost:4000 that browsersync leverages (see gulpfile.js to adjust as needed) | ||
| Once the repo has been cloned successfully (see the main [README.md](https://github.com/plotly/graphing-library-docs/blob/master/README.md#how-to-get-the-application-working-locally)), run `npm install` to install gulp and the necessary dependencies. |
There was a problem hiding this comment.
| Once the repo has been cloned successfully (see the main [README.md](https://github.com/plotly/graphing-library-docs/blob/master/README.md#how-to-get-the-application-working-locally)), run `npm install` to install gulp and the necessary dependencies. | |
| Once you have successfully cloned the repo (see the main [README.md](https://github.com/plotly/graphing-library-docs/blob/master/README.md#how-to-get-the-application-working-locally)), run `npm install` to install gulp and the necessary dependencies. |
Active voice is better for instructions
|
|
||
| **When to update:** Run the appropriate `update_*_search` target whenever a new tutorial is added to the corresponding `_posts/` directory. The `schema` index should be updated when a new plotly.js version is released. | ||
|
|
||
| **How to exclude files from an index:** Each search index has its own Jekyll config (`_config_python_search.yml`, `_config_r_search.yml`, etc.) with an `algolia.excluded_files` list. Add files or paths there to keep them out of search results. |
There was a problem hiding this comment.
Hm, why would we want to keep stuff out of search results?
There was a problem hiding this comment.
Looking at the referenced python YML file, it excludes anything to do with other libraries like plotly.js, plotly.r, etc.
Description
Update the build docs to clarify how to get local dev set up and how to deploy updates to the docs.