@@ -7,36 +7,77 @@ Find and replace all on all files (CMD+SHIFT+F):
77- Description: My new Nuxt module
88-->
99
10- # My Module
10+ # Glaze for Nuxt
1111
1212[ ![ npm version] [ npm-version-src ]] [ npm-version-href ]
1313[ ![ npm downloads] [ npm-downloads-src ]] [ npm-downloads-href ]
14- [ ![ License] [ license-src ]] [ license-href ]
15- [ ![ Nuxt] [ nuxt-src ]] [ nuxt-href ]
14+ [ ![ License] [ license-src ]] [ license-href ] [ ![ Nuxt] [ nuxt-src ]] [ nuxt-href ]
1615
17- My new Nuxt module for doing amazing things.
16+ An (unofficial) [ Glaze ] ( https://glaze.dev/ ) module for Nuxt
1817
19- - [ ✨   ; Release Notes] ( /CHANGELOG.md )
20- <!-- - [🏀 Online playground](https://stackblitz.com/github/your-org/my-module?file=playground%2Fapp.vue) -->
21- <!-- - [📖 Documentation](https://example.com) -->
22-
23- ## Features
24-
25- <!-- Highlight some of the features your module provide here -->
26- - ⛰   ; Foo
27- - 🚠   ; Bar
28- - 🌲   ; Baz
18+ ![ ] ( public/images/og_image.png )
2919
3020## Quick Setup
3121
3222Install the module to your Nuxt application with one command:
3323
3424``` bash
35- npx nuxi module add my-module
25+ npx nuxi module add nuxt-glaze
26+ ```
27+
28+ That's it! You can now use [ Glaze] ( https://glaze.dev/ ) in your Nuxt app ✨
29+
30+ Examples (from their docs):
31+
32+ ``` ts
33+ < div data - animate = ' from:opacity-0.5 to:opacity-1' > </div >
34+ ```
35+
36+ ``` ts
37+ < div data - animate = ' to:scale.x-2|scale.y-2' > </div >
38+ ```
39+
40+ ## Configuration
41+
42+ You can use all settings for glaze in your ` nuxt.config.ts ` under the key
43+ ` glaze ` like so:
44+
45+ ``` typescript
46+ export default defineNuxtConfig ({
47+ modules: [... ],
48+
49+ glaze: {
50+ // the root element which will be searched for elements
51+ element: document ,
52+ // the attribute to search for
53+ dataAttribute: ' data-animate' ,
54+ // custom breakpoints
55+ breakpoints: {
56+ default: ' (min-width: 1px)' ,
57+ },
58+ // defaults for animations
59+ defaults: {
60+ tl: ' ease-power2.inOut' ,
61+ element: ' to:x-500' ,
62+ },
63+ // custom presets
64+ presets: {
65+ helicopter: ' from:rotate-2160|duration-10' ,
66+ },
67+ // watch elements for changes and restart animations with new settings
68+ watch: false ,
69+ },
70+ })
3671```
3772
38- That's it! You can now use My Module in your Nuxt app ✨
73+ Find a full list of options here:
74+ [ Config options for glaze] ( https://glaze.dev/documentation/install#config )
3975
76+ ## Docs
77+
78+ ### Find the full docs and examples here:
79+
80+ [ Documentation] ( https://glaze.dev/documentation )
4081
4182## Contribution
4283
@@ -58,27 +99,20 @@ That's it! You can now use My Module in your Nuxt app ✨
5899
59100 # Run ESLint
60101 npm run lint
61-
62- # Run Vitest
63- npm run test
64- npm run test:watch
65-
66- # Release new version
67- npm run release
68102 ```
69103
70104</details >
71105
72-
73106<!-- Badges -->
74- [ npm-version-src ] : https://img.shields.io/npm/v/my-module/latest.svg?style=flat&colorA=020420&colorB=00DC82
75- [ npm-version-href ] : https://npmjs.com/package/my-module
76107
77- [ npm-downloads-src ] : https://img.shields.io/npm/dm/my-module.svg?style=flat&colorA=020420&colorB=00DC82
108+ [ npm-version-src] :
109+ https://img.shields.io/npm/v/my-module/latest.svg?style=flat&colorA=020420&colorB=00DC82
110+ [ npm-version-href ] : https://npmjs.com/package/my-module
111+ [ npm-downloads-src] :
112+ https://img.shields.io/npm/dm/my-module.svg?style=flat&colorA=020420&colorB=00DC82
78113[ npm-downloads-href ] : https://npm.chart.dev/my-module
79-
80- [ license-src ] : https://img.shields.io/npm/l/my-module.svg?style=flat&colorA=020420&colorB=00DC82
114+ [ license-src ] :
115+ https://img.shields.io/npm/l/my-module.svg?style=flat&colorA=020420&colorB=00DC82
81116[ license-href ] : https://npmjs.com/package/my-module
82-
83117[ nuxt-src ] : https://img.shields.io/badge/Nuxt-020420?logo=nuxt.js
84118[ nuxt-href ] : https://nuxt.com
0 commit comments