Skip to content
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

Documentation amended to be available in printable format #2830

Closed
wants to merge 6 commits into from
Closed

Documentation amended to be available in printable format #2830

wants to merge 6 commits into from

Conversation

SetTrend
Copy link
Contributor

@SetTrend SetTrend commented Feb 24, 2019

This is a follow-up to #2754

Currently, it's not possible to create a decent printed (or PDF) version of the documentation:

  1. Printed pages show all the navigation and interactive chrome, thereby unnecessarily wasting space.
  2. Printing all of a chapter's pages to get a comprehensive lecture wastes a lot of space when each of a chapter's pages gets printed separately.

This commit fixes both issues:

  1. New CSS rules have been added to remove navigation and interactive chrome when printing a documentation page.
  2. A Node script has been added to concatenate a chapter's Markdown documents into a single page.

To do:

The webpack documentation team is suggested to add my new Node script to their build script and to
publish the generated concatenated content, converted to HTML, as additional Hyperlinks in the doc on their website (e.g. "→ Printable version").

…umentation files from single files.

Currently, it's not possible to create a decent printed (or PDF) version of the documentation:

(a) Printed pages show all the navigation and interactive chrome, thereby unnecessarily wasting space.
(b) Printing all of a chapter's pages to get a comprehensive lecture wastes a lot of space when
    each of a chapter's pages gets printed separately.

This commit fixes both issues:

(a) New CSS rules have been added to remove navigation and interactive chrome when printing a
    documentation page.
(b) A Node script has been added to concatenate a chapter's Markdown documents into a single page.

To do:

The webpack documentation team is suggested to add the new Node script to the build script and to
publish the generated concatenated content, converted to HTML, on their website for printing.
@montogeek
Copy link
Member

@SetTrend What problem did you have when building it?

@SetTrend
Copy link
Contributor Author

SetTrend commented Feb 24, 2019

@montogeek: Sorry, my mistake. I confused this project with another one I'm contributing to. The other project uses bash commands I cannot run.

So, after running npm run serve I edited my pull request comment accordingly now.

@SetTrend
Copy link
Contributor Author

I successfully ran npm run chapterize and npm run build.

The document pages look excellent when printed.

Still, I can't find the help files generated by npm run chapterize anywhere in the result. I was able, though, to convert the generated "_all.md" files manually to HTML and print them. So, the chapterize task runs flawlessly.

@SetTrend
Copy link
Contributor Author

Hi @EugeneHlushko: What is the state of this pull request?

@EugeneHlushko
Copy link
Member

Hi @SetTrend ,
I've updated your branch to be up-to-date with latest master and will try it locally, make sure to pull the changes. Thanks for reminding

@EugeneHlushko
Copy link
Member

Meanwhile, can you give me permissions on your fork so i can contribute to the branch too?

@montogeek
Copy link
Member

You should have, I can commit into forks

@EugeneHlushko
Copy link
Member

oh, okay let me try

@EugeneHlushko
Copy link
Member

EugeneHlushko commented Mar 28, 2019

I am struggling to build local/prod version on this branch, cannot see obvious reasons tho.

ERROR in ./index.jsx 48:21
Module parse failed: Unexpected token (48:21)
You may need an appropriate loader to handle this file type.
|           'import': function _import(path) {
|             if (path === entryPath) {
>               return import('./content/' + path);
|             } else if (path === '/vote') {
|               return import('./components/' + path);
 @ multi ../node_modules/webpack-dev-server/client?http://localhost:3000 ../node_modules/webpack/hot/dev-server.js ./index.jsx index[2]

Same for prod run... but looks like branch is up-to-date did rebase go wrong ? ❓

@SetTrend
Copy link
Contributor Author

SetTrend commented Apr 1, 2019

Unfortunately I cannot be of any help here. The build process now requires Python, which I don't have on my Windows machine.

I'm working on a new client project now, so, I don't think I'm able to go through the pain of installing and learning Python before being able to commit anything.

Would it help to cherry-pick my changes?

@EugeneHlushko
Copy link
Member

Yeah its an option, not sure i can cherry pick cross fork

@montogeek
Copy link
Member

This is now possible, thanks!

@montogeek montogeek closed this Jun 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants