Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(js-runtime,docs): add
navigator.userAgent
API (#396)
- Loading branch information
Showing
6 changed files
with
41 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,20 @@ | ||
{ | ||
"$schema": "https://unpkg.com/@changesets/config@2.0.1/schema.json", | ||
"changelog": ["@changesets/changelog-github", { "repo": "lagonapp/lagon" }], | ||
"changelog": [ | ||
"@changesets/changelog-github", | ||
{ | ||
"repo": "lagonapp/lagon" | ||
} | ||
], | ||
"commit": false, | ||
"fixed": [], | ||
"fixed": [ | ||
[ | ||
"@lagon/runtime", | ||
"@lagon/js-runtime" | ||
] | ||
], | ||
"linked": [], | ||
"access": "public", | ||
"baseBranch": "main", | ||
"updateInternalDependencies": "patch" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
'@lagon/docs': minor | ||
'@lagon/js-runtime': minor | ||
--- | ||
|
||
Add `navigator.userAgent` API |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// esbuild will inline the version as a const, and since both | ||
// runtime and js-runtime are versioned together, we can safely | ||
// import the version from the package.json instead of injecting | ||
// it from the Rust code. | ||
import { version } from '../../../package.json'; | ||
|
||
(globalThis => { | ||
globalThis.navigator = { | ||
...globalThis.navigator, | ||
userAgent: `Lagon/${version}`, | ||
}; | ||
})(globalThis); |
f538576
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.
Successfully deployed to the following URLs:
docs – ./packages/docs
docs-git-main-lagon.vercel.app
lagon-docs.vercel.app
docs-lagon.vercel.app
docs.lagon.app