https://github.com/lgkonline/put-version
A small tool to put the version from your package.json to all ressources in a HTML document.
https://github.com/lgkonline/put-version
command-line-tool config format formatting prettier tool
Last synced: 10 months ago
JSON representation
A small tool to put the version from your package.json to all ressources in a HTML document.
- Host: GitHub
- URL: https://github.com/lgkonline/put-version
- Owner: lgkonline
- License: mit
- Created: 2017-11-24T10:08:39.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-11-28T15:32:15.000Z (over 7 years ago)
- Last Synced: 2025-08-09T13:44:12.648Z (11 months ago)
- Topics: command-line-tool, config, format, formatting, prettier, tool
- Language: JavaScript
- Homepage:
- Size: 41 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# put-version
With this tool you can archieve to turn this:
```
```
to this:
```
```
## Why?
Browsers cache scripts and stylesheets. When you change the path like this you force the browser to receive the latest versions.
## Install
Install it easily with NPM:
```
npm i put-version -D
```
## Usage
```
put-version [filePath]
```
Example: `put-version ./index.html`
Then you should register it your `package.json` so it will always get executed when you create a new build:
```
{
"name": "your-app",
"version": "1.0.0",
"scripts": {
"build": "put-version ./index.html"
},
...
}
```