Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kwaa/hexo-partytown
🎉 Partytown Integration for Hexo
https://github.com/kwaa/hexo-partytown
hexo hexo-filter hexo-plugin hexojs partytown performance typescript web-worker webworker
Last synced: 16 days ago
JSON representation
🎉 Partytown Integration for Hexo
- Host: GitHub
- URL: https://github.com/kwaa/hexo-partytown
- Owner: kwaa
- License: wtfpl
- Created: 2022-08-21T17:22:49.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-10-11T13:00:52.000Z (about 2 years ago)
- Last Synced: 2024-12-01T11:43:53.665Z (about 1 month ago)
- Topics: hexo, hexo-filter, hexo-plugin, hexojs, partytown, performance, typescript, web-worker, webworker
- Language: TypeScript
- Homepage: https://npmjs.com/package/hexo-partytown
- Size: 104 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
Awesome Lists containing this project
README
# hexo-partytown
🎉 [Partytown](https://github.com/BuilderIO/partytown) Integration for [Hexo](https://github.com/hexojs/hexo)
## Install
```bash
pnpm add hexo-partytown # pnpm
yarn add hexo-partytown # yarn
npm i hexo-partytown # npm
```## Config
```ts
type HexoPartytownConfig = {
/**
* Script matching fields
* @remarks If using an array, run as `new RegExp(arr[0], arr[1])`
* @defaultValue `[['^https://.+.min.js$', 'i']]`
*/
match: (string | [string, string])[]
/**
* Script matching range
* @defaultValue `html`
*/
range: string
/**
* Partytown Snippet
* @defaultValue `inline`
*/
snippet: string | false
/**
* Copy Library Files
* @defaultValue `true`
*/
copylib: boolean
/**
* Partytown Configuration
* @see {@link https://partytown.builder.io/configuration}
*/
config?: PartytownConfig
}
```Write into `_config.yml` to override default value.
```yaml
partytown:
config:
debug: true
forward:
- dataLayer.push
```## License
Licensed under the [WTFPL](http://www.wtfpl.net), See the [COPYING](COPYING) file for more details.