@@ -78,9 +78,9 @@ export default createLibConfig({
7878})
7979```
8080
81- ## Notes
81+ ### Notes
8282
83- ### Inlining / injecting CSS
83+ #### Inlining / injecting CSS
8484You can enable inlining CSS code, but please note that this is handled differently for apps and libraries.
8585* Apps will inline the CSS by dynamically inject it as ` script ` tags
8686* Libraries will extract the CSS to the dist/assets directory and import it in the entry point
@@ -90,3 +90,27 @@ But this only works in DOM environments, so for libraries this might not work (e
9090
9191So for libraries the CSS will still be extracted by Vite, but the extracted CSS assets will be imported.
9292This way the library user can decide how to handle the imported CSS without relying on a DOM environment.
93+
94+ ## Development
95+
96+ ### 📤 Releasing a new version
97+
98+ - Pull the latest changes from ` main ` or ` stableX `
99+ - Checkout a new branch with the tag name (e.g ` v4.0.1 ` ): ` git checkout -b v<version> `
100+ - Run ` npm version patch --no-git-tag-version ` (` npm version minor --no-git-tag-version ` if minor).
101+ This will return a new version name, make sure it matches what you expect
102+ - Generate the changelog content from the [ release] ( https://github.com/nextcloud-libraries/nextcloud-vite-config/releases ) page.
103+ Create a draft release, select the previous tag, click ` generate ` then paste the content to the ` CHANGELOG.md ` file
104+ 1 . adjust the links to the merged pull requests and authors so that the changelog also works outside of GitHub
105+ by running ` npm run prerelease:format-changelog ` .
106+ This will apply this regex: ` by @([^ ]+) in ((https://github.com/)nextcloud-libraries/nextcloud-vite-config/pull/(\d+)) `
107+ Which this as the replacement: ` [\#$4]($2) \([$1]($3$1)\) `
108+ 2 . use the the version as tag AND title (e.g ` v4.0.1 ` )
109+ 3 . add the changelog content as description (https://github.com/nextcloud-libraries/nextcloud-vite-config/releases )
110+ - Commit, push and create PR
111+ - Get your PR reviewed and merged
112+ - Create a milestone with the follow-up version at https://github.com/nextcloud-libraries/nextcloud-vite-config/milestones
113+ - Move all open tickets and PRs to the follow-up
114+ - Close the milestone of the version you release
115+ - Publish the previously drafted release on GitHub
116+ ![ image] ( https://user-images.githubusercontent.com/14975046/124442568-2a952500-dd7d-11eb-82a2-402f9170231a.png )
0 commit comments