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

Switch to Hugo #28014

Merged
merged 23 commits into from Mar 13, 2019
Merged

Switch to Hugo #28014

merged 23 commits into from Mar 13, 2019

Conversation

@XhmikosR
Copy link
Member

@XhmikosR XhmikosR commented Jan 9, 2019

TODO:

  • make sure our folder structure is the proper one for what we want to achieve. Also see if we can make folders nesting level smaller, maybe by using permalinks or something. For content and static.
  • Review the new Chroma styles
  • audit the changes by bep or someone familiar with Hugo

TODO (can be sorted out maybe after the merge)

  • can we generate SRI hashes for existent files on the fly? For bootstrap.min.css, bootstrap.min.js, bootstrap.bundle.min.js, popper.js/1.14.7/umd/popper.min.js. This would simplify things as we could remove the release-sri script
  • get image width/height with Hugo when possible (examples images, homepage)
  • maybe use Hugo Extended version for docs' CSS?
  • bep's suggestion:

    Re.

    {{< partial "callout-warning-color-assistive-technologies.md" >}}
    

    The partial above uses the partial func to load, parse and execute templates. This has its limitations and is possibly ineffective.
    I would recommend that you store your callouts (and other content files you want to include) in a so-called headless bundle -- and load them via .GetPage. This way you can use markdown + shortcodes etc.

  • bep's suggestion:

    Ref. {{ block "header" . }} in your single.html template.
    Blocks only make sense inside base template(s) (i.e. baseof.html), which I cannot see. I would highly recommend that you restructure your templates to use them. It removes some repetition.


Fixed issues
  • fix Netlify previews; fixed with the relative URLs
  • make sure all layouts are fine
    • homepage
      • Fix variables in code snippets
    • examples
      • index page
      • individual examples are not being generated at all
    • versions
      • sort versions in reverse
      • fix 4.0 showing up as 4; fixed by using strings in data files
  • fix partial include/icons
  • fix docs sidebar menu; see if we can still use a data file for this
    • fix single menu item (Migrate)
  • placeholder shortcode: backport the latest v4-dev changes
  • Fix bugify
  • Example shortcode
    • remove the placeholder SVG etc
    • Fix nested placeholder like in media object second example; the regex is too overzealous. We might need to split the string like we currently do.
    • remove the extra newline when there's a placeholder image
    • add default lang html for example shortcode; it seems we only pass HTML
    • support hide_markup or nohighlight in example shortcode and adapt content
    • Use false for text and title in the example shortcode instead of " "
  • fix ToC styling
  • whitespace control
  • Streamline the inline shortcodes whitespace
  • make sure the HTML comments we really want to keep are kept
  • Fix the remaining inline HTML content cases
  • Regenerate Chroma/Pygments styles and adapt it
  • Report/Work around the stray p tags issue
  • Figure out/report why https://github.com/twbs/bootstrap/pull/28014/files#diff-cadd93f34018d2674cc31bd8da855e07R352 isn't rendered as HTML
  • compare the number of generated pages so that we don't have extra/missing ones like /docs/index.html
  • Before the merge:
    • Remove --renderToDisk from docs-serve script
    • Remove any temp commits

Fixes #24475

Preview: https://deploy-preview-28014--twbs-bootstrap.netlify.com/

@XhmikosR XhmikosR added the docs label Jan 9, 2019
@XhmikosR XhmikosR requested review from twbs/css-review as code owners Jan 9, 2019
@XhmikosR XhmikosR added the build label Jan 9, 2019
@XhmikosR XhmikosR force-pushed the v4-dev-xmr-hugo-2 branch 2 times, most recently from 35dd8ec to 97859e0 Jan 10, 2019
@XhmikosR XhmikosR mentioned this pull request Jan 15, 2019
@XhmikosR XhmikosR force-pushed the v4-dev-xmr-hugo-2 branch 8 times, most recently from 74bc5ce to 6fbdc80 Jan 15, 2019
@XhmikosR XhmikosR force-pushed the v4-dev-xmr-hugo-2 branch from 6fbdc80 to a7b82b6 Jan 24, 2019
@XhmikosR
Copy link
Member Author

@XhmikosR XhmikosR commented Jan 24, 2019

If anyone is familiar with Hugo and has some time, I could use some help here.

I really want us to make the switch, we just need some help setting things up.

@BhaveshSGupta

This comment has been hidden.

@XhmikosR

This comment has been hidden.

@XhmikosR XhmikosR force-pushed the v4-dev-xmr-hugo-2 branch 8 times, most recently from 5abce52 to 014827e Jan 25, 2019
@XhmikosR XhmikosR force-pushed the v4-dev-xmr-hugo-2 branch from b612a75 to c8f4cc5 Mar 12, 2019
Copy link
Member

@bardiharborow bardiharborow left a comment

I can't vouch for everything here, but seems 95% so let's merge and get on with it. 😅

@mdo
mdo approved these changes Mar 13, 2019
@XhmikosR XhmikosR merged commit 02e0aa3 into master Mar 13, 2019
5 checks passed
5 checks passed
bundlesize Good job! bundle size < maxSize
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 91.059%
Details
deploy/netlify Deploy preview ready!
Details
v5 automation moved this from Approved to Shipped Mar 13, 2019
@XhmikosR XhmikosR deleted the v4-dev-xmr-hugo-2 branch Mar 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
v5
  
Shipped
Linked issues

Successfully merging this pull request may close these issues.

8 participants