-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Add note about loading the "latest" Primer CSS version #1784
Conversation
|
@@ -19,12 +19,14 @@ This method requires no dev environment set up and is useful for when you want t | |||
<head> | |||
<title></title> | |||
<meta name="viewport" content="width=device-width, initial-scale=1" /> | |||
<link rel="stylesheet" href="https://unpkg.com/@primer/css@^16.0.0/dist/primer.css" /> | |||
<link rel="stylesheet" href="https://unpkg.com/@primer/css@^19.0.0/dist/primer.css" /> |
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.
Would it be possible to import the current version from package.json
and interpolate it here?
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.
That would be great. Not sure if it's possible inside of these "code examples"? 🤔
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.
I've had a go and it seems you can if you use <code>
instead of a md code snippet 🎉
<code class="language-html">
{`<!DOCTYPE html>
<html lang="en">
<head>
<title></title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="https://unpkg.com/@primer/css@^${packageJson.version}/dist/primer.css" />
</head>
<body></body>
</html>`}
</code>
Bit uglier but I think it's preferable to manually updating this page.
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.
* Updating and autofixing stylelint * Moving config to primer/stylelint-config * Removing unused disables from css * Stylelint auto-fixes * @primer/stylelint-config@12.2.0 * Remove these from workfow * Use reusable release_canary workflow (#1811) * Use reusable release_canary workflow * Install with yarn Co-authored-by: Jon Rohan <yes@jonrohan.codes> * Use counter-border for LHC (#1792) * Use counter-border for LHC * Create orange-ties-sin.md * Remove fallback * UnderlineNav `:focus` styles (#1764) * add pseudo selectors * adjustments * add stories, cleanup * update mixin * fix mixin * lint * add back overflow styles * adjust focus for better overflow state, scrollsnap * post test adjustments, move hacks to primer css * Stylelint auto-fixes * hover state desktop only * document data-content hack * Create nice-days-jog.md Co-authored-by: Actions Auto Build <actions@github.com> Co-authored-by: simurai <simurai@github.com> * Add note about loading the "latest" Primer CSS version (#1784) * Add stashing * Stylelint auto-fixes Co-authored-by: Actions Auto Build <actions@github.com> Co-authored-by: Cole Bemis <colebemis@github.com> Co-authored-by: simurai <simurai@github.com> Co-authored-by: Katie Langerman <langermank@github.com>
This updates the import of Primer CSS to
19.0.0
. Also adds a not in case you want always the "latest" version, with the risk of including breaking changes.