Skip to content

Commit

Permalink
chore(proposal): add html meta tag to sdk-demo (#444)
Browse files Browse the repository at this point in the history
* chore(client): add html meta tag to sdk-demo

* docs(changeset): chore: add meta hmtl tag for package version in index.html file on bundling process
  • Loading branch information
vkuprin authored Nov 22, 2024
1 parent 7b1c6a2 commit 2b602ef
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/lazy-items-brush.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@team-monite/sdk-demo': minor
---

chore: add meta hmtl tag for package version in index.html file on bundling process
3 changes: 2 additions & 1 deletion packages/sdk-demo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@
"@openapi-qraft/react": "1.14.0",
"@tanstack/react-query": "~5.28.6",
"@tanstack/react-query-devtools": "~5.28.6",
"@team-monite/sdk-themes": "workspace:~"
"@team-monite/sdk-themes": "workspace:~",
"vite-plugin-html-config": "~2.0.2"
}
}
13 changes: 13 additions & 0 deletions packages/sdk-demo/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,18 @@ import react from '@vitejs/plugin-react-swc';

import { resolve } from 'path';
import { defineConfig } from 'vite';
import htmlPlugin from 'vite-plugin-html-config';

import { version } from './package.json';

const htmlPluginOpt = {
metas: [
{
name: 'version',
content: version,
},
],
};

export default async function viteConfig() {
return defineConfig({
Expand All @@ -13,6 +25,7 @@ export default async function viteConfig() {
['@swc/plugin-emotion', {}],
],
}),
htmlPlugin(htmlPluginOpt),
],
build: {
rollupOptions: {
Expand Down
10 changes: 10 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8467,6 +8467,7 @@ __metadata:
ts-node: "npm:~10.9.1"
typescript: "npm:~5.5.4"
vite: "npm:~5.4.9"
vite-plugin-html-config: "npm:~2.0.2"
web-vitals: "npm:^2.1.4"
yup: "npm:~0.32.11"
languageName: unknown
Expand Down Expand Up @@ -25927,6 +25928,15 @@ __metadata:
languageName: node
linkType: hard

"vite-plugin-html-config@npm:~2.0.2":
version: 2.0.2
resolution: "vite-plugin-html-config@npm:2.0.2"
peerDependencies:
vite: ">=5.0.0"
checksum: 10/ac80a172f2ed00b72285d190ea32d113fb063d9839b938308ab669f5f0bc4ea19cb922b15da56749a7685ffe4dec0caf4a8c136536df74eef65c34984db954b4
languageName: node
linkType: hard

"vite@npm:~5.1.8":
version: 5.1.8
resolution: "vite@npm:5.1.8"
Expand Down

0 comments on commit 2b602ef

Please sign in to comment.