Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zacharycrespin/11ty-external-file-downloader
https://github.com/zacharycrespin/11ty-external-file-downloader
11ty eleventy npm
Last synced: 1 day ago
JSON representation
- Host: GitHub
- URL: https://github.com/zacharycrespin/11ty-external-file-downloader
- Owner: ZacharyCrespin
- License: gpl-3.0
- Created: 2023-05-23T01:24:14.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-06-06T16:46:42.000Z (over 1 year ago)
- Last Synced: 2024-12-21T20:34:31.535Z (1 day ago)
- Topics: 11ty, eleventy, npm
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/11ty-external-file-downloader
- Size: 16.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 11ty-external-file-downloader
## Usage
### Install
`npm i 11ty-external-file-downloader`### Basic Usage
```js
// .eleventy.js
const downloader = require('11ty-external-file-downloader');module.exports = function(eleventyConfig) {
eleventyConfig.addPlugin(downloader, {
urls: [
'https://example.com/cool.css',
'https://example.com/dope.js'
]
});
}
```
### Options
`urls`
- default: `[]`
- syntax: list`directory`
- default: `_site/external`
- syntax: a string reletive to root dir`fileName`
- default: `[name].[ext]`
- syntax: string
- `[name]` = the original file name (excluding extention)
- `[ext]` = the extention of the original file