File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,26 @@ module.exports = function (eleventyConfig) {
2727};
2828```
2929
30+ If you would like to compile more than 1 svgsprite, pass an array of config objects with unique ` svgSpriteShortcode ` ** (important)** :
31+
32+ ``` js
33+ const svgSprite = require (" eleventy-plugin-svg-sprite" );
34+
35+ module .exports = function (eleventyConfig ) {
36+ eleventyConfig .addPlugin (svgSprite, [
37+ {
38+ path: " ./src/assets/svg_1" , // relative path to SVG directory
39+ svgSpriteShortcode: " svgsprite1" ,
40+ },
41+ {
42+ path: " ./src/assets/svg_2" , // relative path to SVG directory
43+ svgSpriteShortcode: " svgsprite2" ,
44+ }
45+ ]);
46+ };
47+ ```
48+ Refer to [ demo/array_config/.eleventy.js] ( ./demo/array_config/.eleventy.js ) for a sample.
49+
3050## Config Options
3151
3252| Option | Type | Default | Description |
You can’t perform that action at this time.
0 commit comments