-
Notifications
You must be signed in to change notification settings - Fork 45
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
Improve UIKit Rendering Performance + Speed Up CI Installs #1255
Conversation
…ng the nav collapse behavior while in vertical mode + hide extra icons
…ting thrown in IE 11
…ck to ensure a fresh install on Travis
…com/bolt-design-system/bolt into feature/uikit-pre-rendering-updates # Conflicts: # packages/uikit-workshop/package.json # yarn.lock
…ch testing config
…ate the dependencies in Bolt's shared Babel config
@sghoweri Side question, this page (https://boltdesignsystem-pg0ps1k83.now.sh/pattern-lab/?p=viewall-visual-styles-rendering-performance) does not belong in the Visual Styles section, can we move it somewhere else? There are already some hidden test pages under button. |
@mikemai2awesome Move it to a new Ions section? 😉 In all seriousness, I'd be ok hiding those for now (underscores) and we come up with a much more permanent home for supporting pages / sections like that |
@sghoweri Sounds like a plan! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just hide some pages as mentioned above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks good. I have only one question, why view all pages like (Color Palette, Typography, Accordion etc.) have left, right padding and specific pages not. I now that was the same on previous build but maybe we should change it.
@mikemai2awesome all set! |
@adamszalapski that's always been the case -- even all the way back with the earliest v1.x releases of Bolt: https://v1-3-0.bolt-design-system.com/pattern-lab/patterns/01-styleguide Pattern Lab has always (historically) had it's "View All" pages include a little bit of padding in the wrapping template since they displaying a high level overview of everything in the system. Individual component-specific pages don't have this wrapper (it's just the pure component as-is), hence why they don't have this padding. |
# Conflicts: # package.json # packages/servers/ssr-server/package.json # yarn.lock
Changes requested should be all set!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sghoweri tested locally and on stage, ran start
and build
, reviewed (most) code changes. Approved 👍
I merged in master and resolved conflicts. Just take a look at package.json
to make sure it's as expected (see commit).
Excellent - thanks @danielamorse!! |
Jira
http://vjira2:8080/browse/BDS-1557
Summary
DevOps related updates to upgrade Bolt’s Puppeteer instances to now use
Puppeteer Core
+ launch using an instance of Chrome already installed; significantly speeding up / slimming down local dev installs + shaving nearly a minute off of our Travis CI build!Also includes a handful of UIKit visual improvements + a ton of IE-specific bug fixes that popped up when testing out these updates.
Before:
After:
Details
This PR updates dependencies and configuration logic for Bolt’s Puppeteer instanced to now use the much lighter weight Puppeteer Core instead (which doesn’t automatically download Chrome when installing). This includes:
Updated NPM dependencies for the root monorepo
package.json
, in addition to updating dependencies in Pattern Lab's UI (UIKit Workshop),@bolt/core
, and Bolt's shared Babel-specific configFixed the double CLI output issue when Pattern Lab's UIKit assets are compiled
Fixed a few misc eslint / prettier related issues flagged after updating dependencies
Added / updated several missing polyfills required to get IE 11 working as expected
Removed Prettier from getting used to format code in the Pattern Lab code viewer due to major performance issues encountered (now using a lighter weight alternative)
Reverted Pattern Lab's iframe to no longer automatically resize when the height changes. This addresses side-effects we've been seeing with sticky / fixed position UI (like modals) + helps improve the already heavy performance load when navigating between pages
Updated Pattern Lab's iframe scrollbar / iframe resizer handle to be easier to use while keeping out of the way
Improvements to the no-JS / pre-rendered version of the docs site -- the nav + iframe are nav both scrollable / usable!
Prerendering Before vs After Updates
What's Up With The New UIKit-specific Packages?
Our modernized Pattern Lab UI had been using two off the shelf Webpack plugins (
critical-css-webpack-plugin
andprerender-spa-plugin
) to handle the pre-rendering and Critical CSS-related work. Unfortunately, these two plugins (and theprerenderer
dependency used for pre-rendering) were also using the heavier version of Puppeteer.This, combined with a lack of recent upstream updates, meant that configuring these Puppeteer instances to use Puppeteer Core + reference the path to a local instance of Chrome installed was incredibly difficult.
For at least the time being, these 3 dependencies have been pulled into the Bolt monorepo to apply the necessary optimizations.
How to test