-
Notifications
You must be signed in to change notification settings - Fork 6
Upgrading from 1.x to 2.x
Version 2.0 of Page Kit upgrades its dependencies on n-ui-foundations
from v4 to v6.
This requires that when any consuming apps upgrade to this version of Page Kit, they also upgrade their Bower dependencies that have their own dependency on n-ui-foundations
to a version that also consumes v6.
Those packages include:
n-knowledge-builder
n-image
n-content-body
n-live-chat
n-myft-ui
n-profile-ui
n-syndication
n-topic-search
n-alert-banner
n-handlebars
n-topic-card
n-messaging-client
n-newsletter-signup
next-consent-proxy
next-messaging-guru
next-myft-email
n-internal-tool
n-magnet
next-syn-list
n-ui-foundations
v6 removes the snappy grid as default. Because Page Kit provides multiple entry points for acquiring stylesheets assets, the required fix to maintain a snappy grid (until such time that we decide to migrate to a fluid grid) is to amend the usage of the dotcom-build-sass
package in the consuming app's webpack.config.js
:
-new PageKitSassPlugin()
+new PageKitSassPlugin({ prependData: '$o-grid-mode: \'snappy\';' })
This will add the $o-grid-mode
variable with a value of 'snappy' to the start of the transpiled CSS file.
N.B. The functionality for dotcom-build-sass
to apply the prependData
option in the arguments was added in v2.0.1, so the consuming app must be able to acquire this version to handle that argument.
Consuming apps upgrading to this version of Page Kit should be checked for layout consistency with production before merging and deploying.