replace-temp-values
v0.1.5
Published
Replace marked template values in file
Downloads
2
Maintainers
Readme
Replace Template Values
A tiny module for replacing template values in a file.
Values to be replaced should be book ended with %%.
Installation
npm install replace-temp-values --save
Usage
myFile.txt
%Heading%
Welcome to this months newsletter
...
%Footer%
app.js
var replace = require('replace-temp-values');
var values = {'Heading': 'Good Morning San Diego!', 'Footer': 'Yaz Flute'};
replace('myFile.txt', 'newFile.txt', values);
- 0.1.5