kidwm / grunt-ssi Goto Github PK
View Code? Open in Web Editor NEWGrunt Plugin to compile HTML with SSI into static HTML pages
License: MIT License
Grunt Plugin to compile HTML with SSI into static HTML pages
License: MIT License
Include support for the #set tag to set local variables while processing
<style>
#include file="index.css"
</style>
<style>
<style>[There was an error processing this include]
</style>
#include file="index.html"
<div>
test
</div>
[There was an error processing this include]
<div>
test
</div>
<div>
test
</div>
I'd like to be able to load SSI templates from the web instead of it being relative to my local files.
Here is a sample of what i was thinking but open to other ideas:
ssi: {
options: {
cache: 'all',
baseDir: 'http://sample.com'
},
myTarget: {
files: [{
expand: true,
src: '**/index.html',
ext: '.html'
}]
}
},
ssi: {
options: {
},
files: [{
expand: true,
cwd: 'html',
src: ['apps/*.html'],
dest: 'apps/html'
}],
},
Running "ssi:files" (ssi) task
Warning: undefined is not a function Use --force to continue.
Aborted due to warnings.
there's a pull request for this issue.
would you update?
Need to Allow for parsing of all SSI include tag structures as in
Add ability to config certain settings for SSI
or
// ...
....
wrapper: '<script><%= file %></script>',
banner: 'Copyright ... <%= file %>'
<!-- #include file="file.js" -->
Copyright ... file.js
<script>
// ..code
</script>
Apparently the signature of writeFileSync has changed or doesn't like the encoding to be passed as part of an object anymore and caused repeated runs to create empty results (due to the files not being written correctly).
Changing Line 182 in lib/ssi.js from
fs.writeFileSync(filePath, data, {endcoding: encode});
to
fs.writeFileSync(filePath, data, encode);
fixes an issue I had with those cache files.
Hi, I'm the new maintainer of node-ssi.
https://github.com/kidwm/node-ssi
I can take over this project and make this grunt plugin based on node-ssi.
my npm id is also kidwm, how do you think, would you like to transfer it to me?
Allow for #echo tag to output to the processed html
Add support for evaluating expressions and handling conditional structures
I use a shared folder for caching, and cacheDir
removes all files in the directory!
Tried to name my src directory "app" but it wouldn't pull in the includes.
It's fucking error.
You'd show the path to the requested file
Currently there is no proper testing implemented into the project, except for basic check if the output looks right.
Need to rewrite lib/ssi.js to be more testable.
Left in a lot of unneccesary logging calls
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.