@tsparticles/template-scaffold 4.1.3 → 4.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (168) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/README.md +3 -0
  3. package/package.json +4 -3
  4. package/template/angular/LICENSE +21 -0
  5. package/template/angular/package.json +1 -1
  6. package/template/angular-confetti/.browserslistrc +6 -0
  7. package/template/angular-confetti/.editorconfig +9 -0
  8. package/template/angular-confetti/LICENSE +21 -0
  9. package/template/angular-confetti/README.md +10 -0
  10. package/template/angular-confetti/angular.json +53 -0
  11. package/template/angular-confetti/gitignore +17 -0
  12. package/template/angular-confetti/package.json +34 -0
  13. package/template/angular-confetti/src/app/app.component.css +15 -0
  14. package/template/angular-confetti/src/app/app.component.html +4 -0
  15. package/template/angular-confetti/src/app/app.component.ts +27 -0
  16. package/template/angular-confetti/src/app/app.module.ts +12 -0
  17. package/template/angular-confetti/src/index.html +12 -0
  18. package/template/angular-confetti/src/main.ts +6 -0
  19. package/template/angular-confetti/src/polyfills.ts +1 -0
  20. package/template/angular-confetti/src/styles.css +5 -0
  21. package/template/angular-confetti/tsconfig.app.json +9 -0
  22. package/template/angular-confetti/tsconfig.json +29 -0
  23. package/template/angular-confetti/tsconfig.spec.json +8 -0
  24. package/template/angular-fireworks/.browserslistrc +6 -0
  25. package/template/angular-fireworks/.editorconfig +9 -0
  26. package/template/angular-fireworks/LICENSE +21 -0
  27. package/template/angular-fireworks/README.md +10 -0
  28. package/template/angular-fireworks/angular.json +53 -0
  29. package/template/angular-fireworks/gitignore +17 -0
  30. package/template/angular-fireworks/package.json +34 -0
  31. package/template/angular-fireworks/src/app/app.component.css +15 -0
  32. package/template/angular-fireworks/src/app/app.component.html +4 -0
  33. package/template/angular-fireworks/src/app/app.component.ts +29 -0
  34. package/template/angular-fireworks/src/app/app.module.ts +12 -0
  35. package/template/angular-fireworks/src/index.html +12 -0
  36. package/template/angular-fireworks/src/main.ts +6 -0
  37. package/template/angular-fireworks/src/polyfills.ts +1 -0
  38. package/template/angular-fireworks/src/styles.css +5 -0
  39. package/template/angular-fireworks/tsconfig.app.json +9 -0
  40. package/template/angular-fireworks/tsconfig.json +29 -0
  41. package/template/angular-fireworks/tsconfig.spec.json +8 -0
  42. package/template/astro/LICENSE +21 -0
  43. package/template/astro/README.md +10 -0
  44. package/template/astro/gitignore +14 -0
  45. package/template/astro/package.json +21 -0
  46. package/template/astro/src/pages/index.astro +35 -0
  47. package/template/ember/LICENSE +21 -0
  48. package/template/ember/README.md +10 -0
  49. package/template/ember/app/controllers/application.js +35 -0
  50. package/template/ember/app/templates/application.hbs +14 -0
  51. package/template/ember/gitignore +14 -0
  52. package/template/ember/package.json +41 -0
  53. package/template/inferno/LICENSE +21 -0
  54. package/template/inferno/README.md +10 -0
  55. package/template/inferno/gitignore +14 -0
  56. package/template/inferno/index.html +12 -0
  57. package/template/inferno/package.json +23 -0
  58. package/template/inferno/src/App.tsx +37 -0
  59. package/template/inferno/src/main.tsx +4 -0
  60. package/template/inferno/tsconfig.json +17 -0
  61. package/template/inferno/vite.config.ts +11 -0
  62. package/template/jquery/LICENSE +21 -0
  63. package/template/jquery/README.md +10 -0
  64. package/template/jquery/gitignore +14 -0
  65. package/template/jquery/index.html +15 -0
  66. package/template/jquery/package.json +19 -0
  67. package/template/jquery/src/main.ts +31 -0
  68. package/template/jquery/src/style.css +22 -0
  69. package/template/jquery/tsconfig.json +19 -0
  70. package/template/jquery/vite.config.ts +5 -0
  71. package/template/lit/LICENSE +21 -0
  72. package/template/lit/README.md +10 -0
  73. package/template/lit/gitignore +14 -0
  74. package/template/lit/index.html +15 -0
  75. package/template/lit/package.json +19 -0
  76. package/template/lit/src/main.ts +8 -0
  77. package/template/lit/src/my-app.ts +34 -0
  78. package/template/lit/src/style.css +21 -0
  79. package/template/lit/tsconfig.json +20 -0
  80. package/template/lit/vite.config.ts +5 -0
  81. package/template/nextjs/LICENSE +21 -0
  82. package/template/nextjs/README.md +10 -0
  83. package/template/nextjs/gitignore +14 -0
  84. package/template/nextjs/package.json +24 -0
  85. package/template/nextjs/src/app/layout.tsx +16 -0
  86. package/template/nextjs/src/app/page.tsx +30 -0
  87. package/template/nextjs/src/app/providers.tsx +13 -0
  88. package/template/nuxt2/LICENSE +21 -0
  89. package/template/nuxt2/README.md +10 -0
  90. package/template/nuxt2/gitignore +14 -0
  91. package/template/nuxt2/nuxt.config.js +3 -0
  92. package/template/nuxt2/package.json +16 -0
  93. package/template/nuxt2/pages/index.vue +43 -0
  94. package/template/nuxt3/LICENSE +21 -0
  95. package/template/nuxt3/README.md +10 -0
  96. package/template/nuxt3/app.vue +36 -0
  97. package/template/nuxt3/gitignore +14 -0
  98. package/template/nuxt3/nuxt.config.ts +3 -0
  99. package/template/nuxt3/package.json +20 -0
  100. package/template/nuxt4/LICENSE +21 -0
  101. package/template/nuxt4/README.md +10 -0
  102. package/template/nuxt4/app.vue +36 -0
  103. package/template/nuxt4/gitignore +14 -0
  104. package/template/nuxt4/nuxt.config.ts +3 -0
  105. package/template/nuxt4/package.json +20 -0
  106. package/template/preact/LICENSE +21 -0
  107. package/template/preact/README.md +10 -0
  108. package/template/preact/gitignore +14 -0
  109. package/template/preact/index.html +12 -0
  110. package/template/preact/package.json +20 -0
  111. package/template/preact/src/App.tsx +43 -0
  112. package/template/preact/src/main.tsx +5 -0
  113. package/template/preact/src/style.css +21 -0
  114. package/template/preact/tsconfig.json +21 -0
  115. package/template/preact/vite.config.ts +7 -0
  116. package/template/qwik/LICENSE +21 -0
  117. package/template/qwik/README.md +10 -0
  118. package/template/qwik/gitignore +14 -0
  119. package/template/qwik/index.html +12 -0
  120. package/template/qwik/package.json +19 -0
  121. package/template/qwik/src/App.tsx +43 -0
  122. package/template/qwik/src/main.tsx +4 -0
  123. package/template/qwik/src/style.css +21 -0
  124. package/template/qwik/tsconfig.json +20 -0
  125. package/template/qwik/vite.config.ts +7 -0
  126. package/template/react/LICENSE +21 -0
  127. package/template/react/package.json +1 -1
  128. package/template/riot/LICENSE +21 -0
  129. package/template/riot/README.md +10 -0
  130. package/template/riot/gitignore +14 -0
  131. package/template/riot/index.html +12 -0
  132. package/template/riot/package.json +21 -0
  133. package/template/riot/src/app.riot +66 -0
  134. package/template/riot/src/main.ts +5 -0
  135. package/template/riot/src/style.css +21 -0
  136. package/template/riot/tsconfig.json +19 -0
  137. package/template/riot/vite.config.ts +7 -0
  138. package/template/solid/LICENSE +21 -0
  139. package/template/solid/package.json +1 -1
  140. package/template/stencil/LICENSE +21 -0
  141. package/template/stencil/README.md +10 -0
  142. package/template/stencil/gitignore +14 -0
  143. package/template/stencil/package.json +19 -0
  144. package/template/stencil/src/components/app-home/app-home.tsx +47 -0
  145. package/template/svelte/LICENSE +21 -0
  146. package/template/svelte/package.json +1 -1
  147. package/template/vanilla/LICENSE +21 -0
  148. package/template/vanilla/package.json +1 -1
  149. package/template/vue2/LICENSE +21 -0
  150. package/template/vue2/README.md +10 -0
  151. package/template/vue2/gitignore +14 -0
  152. package/template/vue2/index.html +12 -0
  153. package/template/vue2/package.json +21 -0
  154. package/template/vue2/src/App.vue +65 -0
  155. package/template/vue2/src/main.ts +14 -0
  156. package/template/vue2/tsconfig.json +19 -0
  157. package/template/vue2/vite.config.ts +7 -0
  158. package/template/vue3/LICENSE +21 -0
  159. package/template/vue3/package.json +1 -1
  160. package/template/webcomponents/LICENSE +21 -0
  161. package/template/webcomponents/README.md +10 -0
  162. package/template/webcomponents/gitignore +14 -0
  163. package/template/webcomponents/index.html +15 -0
  164. package/template/webcomponents/package.json +18 -0
  165. package/template/webcomponents/src/main.ts +9 -0
  166. package/template/webcomponents/src/style.css +22 -0
  167. package/template/webcomponents/tsconfig.json +19 -0
  168. package/template/webcomponents/vite.config.ts +5 -0
@@ -0,0 +1,14 @@
1
+ # dependencies
2
+ /node_modules
3
+
4
+ # production
5
+ /dist
6
+
7
+ # misc
8
+ .DS_Store
9
+ *.local
10
+
11
+ # debug
12
+ npm-debug.log*
13
+ yarn-debug.log*
14
+ yarn-error.log*
@@ -0,0 +1,12 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
+ <title>{{projectName}}</title>
7
+ </head>
8
+ <body>
9
+ <div id="root"></div>
10
+ <script type="module" src="/src/main.tsx"></script>
11
+ </body>
12
+ </html>
@@ -0,0 +1,20 @@
1
+ {
2
+ "name": "{{packageName}}",
3
+ "private": true,
4
+ "version": "1.0.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "tsc && vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "preact": "^10.19.3",
13
+ "@tsparticles/preact": "^4.1.3"
14
+ },
15
+ "devDependencies": {
16
+ "@preact/preset-vite": "^2.8.1",
17
+ "typescript": "^5.7.2",
18
+ "vite": "^6.0.0"
19
+ }
20
+ }
@@ -0,0 +1,43 @@
1
+ import { useEffect } from "preact/hooks";
2
+ import Particles, { initParticlesEngine } from "@tsparticles/preact";
3
+ import { loadSlim } from "@tsparticles/slim";
4
+ import type { ISourceOptions } from "@tsparticles/engine";
5
+
6
+ export default function App() {
7
+ useEffect(() => {
8
+ void initParticlesEngine(async (engine) => {
9
+ await loadSlim(engine);
10
+ });
11
+ }, []);
12
+
13
+ const options: ISourceOptions = {
14
+ fullScreen: { enable: true, zIndex: -1 },
15
+ background: { color: { value: "#1a1a2e" } },
16
+ fpsLimit: 60,
17
+ particles: {
18
+ number: { value: 80, density: { enable: true } },
19
+ color: { value: ["#6c5ce7", "#a29bfe", "#fd79a8"] },
20
+ shape: { type: "circle" },
21
+ opacity: { value: 0.5, random: true },
22
+ size: { value: { min: 1, max: 4 }, random: true },
23
+ move: {
24
+ enable: true,
25
+ speed: 2,
26
+ direction: "none",
27
+ random: false,
28
+ straight: false,
29
+ outModes: { default: "out" },
30
+ },
31
+ },
32
+ detectRetina: true,
33
+ };
34
+
35
+ return (
36
+ <div>
37
+ <div id="app-content">
38
+ <h1>Hello, tsParticles!</h1>
39
+ </div>
40
+ <Particles id="tsparticles" options={options} />
41
+ </div>
42
+ );
43
+ }
@@ -0,0 +1,5 @@
1
+ import { render } from "preact";
2
+ import App from "./App";
3
+ import "./style.css";
4
+
5
+ render(<App />, document.getElementById("root")!);
@@ -0,0 +1,21 @@
1
+ body {
2
+ margin: 0;
3
+ overflow: hidden;
4
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
5
+ }
6
+
7
+ #app-content {
8
+ position: absolute;
9
+ top: 50%;
10
+ left: 50%;
11
+ transform: translate(-50%, -50%);
12
+ z-index: 10;
13
+ text-align: center;
14
+ color: #fff;
15
+ pointer-events: none;
16
+ }
17
+
18
+ h1 {
19
+ font-size: 3.2em;
20
+ text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
21
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2020",
4
+ "useDefineForClassFields": true,
5
+ "module": "ESNext",
6
+ "lib": ["ES2020", "DOM", "DOM.Iterable"],
7
+ "skipLibCheck": true,
8
+ "moduleResolution": "bundler",
9
+ "allowImportingTsExtensions": true,
10
+ "resolveJsonModule": true,
11
+ "isolatedModules": true,
12
+ "noEmit": true,
13
+ "jsx": "preserve",
14
+ "jsxImportSource": "preact",
15
+ "strict": true,
16
+ "noUnusedLocals": true,
17
+ "noUnusedParameters": true,
18
+ "noFallthroughCasesInSwitch": true
19
+ },
20
+ "include": ["src"]
21
+ }
@@ -0,0 +1,7 @@
1
+ import preact from "@preact/preset-vite";
2
+ import { defineConfig } from "vite";
3
+
4
+ export default defineConfig({
5
+ plugins: [preact()],
6
+ base: "./",
7
+ });
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,10 @@
1
+ # {{projectName}}
2
+
3
+ A tsParticles Qwik project scaffolded with [tsparticles-create](https://github.com/tsparticles/tsparticles).
4
+
5
+ ## Getting started
6
+
7
+ ```bash
8
+ npm install
9
+ npm run dev
10
+ ```
@@ -0,0 +1,14 @@
1
+ # dependencies
2
+ /node_modules
3
+
4
+ # production
5
+ /dist
6
+
7
+ # misc
8
+ .DS_Store
9
+ *.local
10
+
11
+ # debug
12
+ npm-debug.log*
13
+ yarn-debug.log*
14
+ yarn-error.log*
@@ -0,0 +1,12 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
+ <title>{{projectName}}</title>
7
+ </head>
8
+ <body>
9
+ <div id="root"></div>
10
+ <script type="module" src="/src/main.tsx"></script>
11
+ </body>
12
+ </html>
@@ -0,0 +1,19 @@
1
+ {
2
+ "name": "{{packageName}}",
3
+ "private": true,
4
+ "version": "1.0.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "tsc && vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "@builder.io/qwik": "^1.12.0",
13
+ "@tsparticles/qwik": "^4.1.3"
14
+ },
15
+ "devDependencies": {
16
+ "typescript": "^5.7.2",
17
+ "vite": "^6.0.0"
18
+ }
19
+ }
@@ -0,0 +1,43 @@
1
+ import { component$, useVisibleTask$ } from "@builder.io/qwik";
2
+ import { Particles, initParticlesEngine } from "@tsparticles/qwik";
3
+ import { loadSlim } from "@tsparticles/slim";
4
+ import type { ISourceOptions } from "@tsparticles/engine";
5
+
6
+ export default component$(() => {
7
+ useVisibleTask$(() => {
8
+ void initParticlesEngine(async (engine) => {
9
+ await loadSlim(engine);
10
+ });
11
+ });
12
+
13
+ const options: ISourceOptions = {
14
+ fullScreen: { enable: true, zIndex: -1 },
15
+ background: { color: { value: "#1a1a2e" } },
16
+ fpsLimit: 60,
17
+ particles: {
18
+ number: { value: 80, density: { enable: true } },
19
+ color: { value: ["#6c5ce7", "#a29bfe", "#fd79a8"] },
20
+ shape: { type: "circle" },
21
+ opacity: { value: 0.5, random: true },
22
+ size: { value: { min: 1, max: 4 }, random: true },
23
+ move: {
24
+ enable: true,
25
+ speed: 2,
26
+ direction: "none",
27
+ random: false,
28
+ straight: false,
29
+ outModes: { default: "out" },
30
+ },
31
+ },
32
+ detectRetina: true,
33
+ };
34
+
35
+ return (
36
+ <div>
37
+ <div id="app-content">
38
+ <h1>Hello, tsParticles!</h1>
39
+ </div>
40
+ <Particles id="tsparticles" options={options} />
41
+ </div>
42
+ );
43
+ });
@@ -0,0 +1,4 @@
1
+ import { render } from "@builder.io/qwik";
2
+ import App from "./App";
3
+
4
+ render(document.getElementById("root") as HTMLElement, <App />);
@@ -0,0 +1,21 @@
1
+ body {
2
+ margin: 0;
3
+ overflow: hidden;
4
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
5
+ }
6
+
7
+ #app-content {
8
+ position: absolute;
9
+ top: 50%;
10
+ left: 50%;
11
+ transform: translate(-50%, -50%);
12
+ z-index: 10;
13
+ text-align: center;
14
+ color: #fff;
15
+ pointer-events: none;
16
+ }
17
+
18
+ h1 {
19
+ font-size: 3.2em;
20
+ text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
21
+ }
@@ -0,0 +1,20 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2020",
4
+ "module": "ESNext",
5
+ "lib": ["ES2020", "DOM", "DOM.Iterable"],
6
+ "skipLibCheck": true,
7
+ "moduleResolution": "bundler",
8
+ "allowImportingTsExtensions": true,
9
+ "resolveJsonModule": true,
10
+ "isolatedModules": true,
11
+ "noEmit": true,
12
+ "jsx": "react-jsx",
13
+ "jsxImportSource": "@builder.io/qwik",
14
+ "strict": true,
15
+ "noUnusedLocals": true,
16
+ "noUnusedParameters": true,
17
+ "noFallthroughCasesInSwitch": true
18
+ },
19
+ "include": ["src"]
20
+ }
@@ -0,0 +1,7 @@
1
+ import { qwikVite } from "@builder.io/qwik/plugin.vite";
2
+ import { defineConfig } from "vite";
3
+
4
+ export default defineConfig({
5
+ plugins: [qwikVite()],
6
+ base: "./",
7
+ });
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -1,5 +1,5 @@
1
1
  {
2
- "name": "{{projectName}}",
2
+ "name": "{{packageName}}",
3
3
  "private": true,
4
4
  "version": "1.0.0",
5
5
  "type": "module",
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,10 @@
1
+ # {{projectName}}
2
+
3
+ A tsParticles Riot project scaffolded with [tsparticles-create](https://github.com/tsparticles/tsparticles).
4
+
5
+ ## Getting started
6
+
7
+ ```bash
8
+ npm install
9
+ npm run dev
10
+ ```
@@ -0,0 +1,14 @@
1
+ # dependencies
2
+ /node_modules
3
+
4
+ # production
5
+ /dist
6
+
7
+ # misc
8
+ .DS_Store
9
+ *.local
10
+
11
+ # debug
12
+ npm-debug.log*
13
+ yarn-debug.log*
14
+ yarn-error.log*
@@ -0,0 +1,12 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
+ <title>{{projectName}}</title>
7
+ </head>
8
+ <body>
9
+ <div id="app"></div>
10
+ <script type="module" src="/src/main.ts"></script>
11
+ </body>
12
+ </html>
@@ -0,0 +1,21 @@
1
+ {
2
+ "name": "{{packageName}}",
3
+ "private": true,
4
+ "version": "1.0.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "riot": "^10.0.0",
13
+ "@tsparticles/riot": "^4.1.3"
14
+ },
15
+ "devDependencies": {
16
+ "@riotjs/compiler": "^10.0.0",
17
+ "rollup-plugin-riot": "^10.0.0",
18
+ "typescript": "^5.7.2",
19
+ "vite": "^6.0.0"
20
+ }
21
+ }
@@ -0,0 +1,66 @@
1
+ <app>
2
+ <div id="app-content">
3
+ <h1>Hello, tsParticles!</h1>
4
+ </div>
5
+ <riot-particles id="tsparticles" options={ state.options }></riot-particles>
6
+
7
+ <script>
8
+ import { initParticlesEngine } from "@tsparticles/riot";
9
+ import { loadSlim } from "@tsparticles/slim";
10
+
11
+ export default {
12
+ state: {
13
+ options: {
14
+ fullScreen: { enable: true, zIndex: -1 },
15
+ background: { color: { value: "#1a1a2e" } },
16
+ fpsLimit: 60,
17
+ particles: {
18
+ number: { value: 80, density: { enable: true } },
19
+ color: { value: ["#6c5ce7", "#a29bfe", "#fd79a8"] },
20
+ shape: { type: "circle" },
21
+ opacity: { value: 0.5, random: true },
22
+ size: { value: { min: 1, max: 4 }, random: true },
23
+ move: {
24
+ enable: true,
25
+ speed: 2,
26
+ direction: "none",
27
+ random: false,
28
+ straight: false,
29
+ outModes: { default: "out" },
30
+ },
31
+ },
32
+ detectRetina: true,
33
+ }
34
+ },
35
+ onMounted() {
36
+ void initParticlesEngine(async (engine) => {
37
+ await loadSlim(engine);
38
+ });
39
+ }
40
+ }
41
+ </script>
42
+
43
+ <style>
44
+ body {
45
+ margin: 0;
46
+ overflow: hidden;
47
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
48
+ }
49
+
50
+ #app-content {
51
+ position: absolute;
52
+ top: 50%;
53
+ left: 50%;
54
+ transform: translate(-50%, -50%);
55
+ z-index: 10;
56
+ text-align: center;
57
+ color: #fff;
58
+ pointer-events: none;
59
+ }
60
+
61
+ h1 {
62
+ font-size: 3.2em;
63
+ text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
64
+ }
65
+ </style>
66
+ </app>
@@ -0,0 +1,5 @@
1
+ import { mount } from "riot";
2
+ import App from "./app.riot";
3
+ import "./style.css";
4
+
5
+ mount(App, "#app");
@@ -0,0 +1,21 @@
1
+ body {
2
+ margin: 0;
3
+ overflow: hidden;
4
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
5
+ }
6
+
7
+ #app-content {
8
+ position: absolute;
9
+ top: 50%;
10
+ left: 50%;
11
+ transform: translate(-50%, -50%);
12
+ z-index: 10;
13
+ text-align: center;
14
+ color: #fff;
15
+ pointer-events: none;
16
+ }
17
+
18
+ h1 {
19
+ font-size: 3.2em;
20
+ text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
21
+ }
@@ -0,0 +1,19 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2020",
4
+ "useDefineForClassFields": true,
5
+ "module": "ESNext",
6
+ "lib": ["ES2020", "DOM", "DOM.Iterable"],
7
+ "skipLibCheck": true,
8
+ "moduleResolution": "bundler",
9
+ "allowImportingTsExtensions": true,
10
+ "resolveJsonModule": true,
11
+ "isolatedModules": true,
12
+ "noEmit": true,
13
+ "strict": true,
14
+ "noUnusedLocals": true,
15
+ "noUnusedParameters": true,
16
+ "noFallthroughCasesInSwitch": true
17
+ },
18
+ "include": ["src"]
19
+ }
@@ -0,0 +1,7 @@
1
+ import riot from "rollup-plugin-riot";
2
+ import { defineConfig } from "vite";
3
+
4
+ export default defineConfig({
5
+ plugins: [riot()],
6
+ base: "./",
7
+ });
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -1,5 +1,5 @@
1
1
  {
2
- "name": "{{projectName}}",
2
+ "name": "{{packageName}}",
3
3
  "private": true,
4
4
  "version": "1.0.0",
5
5
  "type": "module",
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,10 @@
1
+ # {{projectName}}
2
+
3
+ A tsParticles Stencil project scaffolded with [tsparticles-create](https://github.com/tsparticles/tsparticles).
4
+
5
+ ## Getting started
6
+
7
+ ```bash
8
+ npm install
9
+ npm run dev
10
+ ```
@@ -0,0 +1,14 @@
1
+ # dependencies
2
+ /node_modules
3
+
4
+ # production
5
+ /dist
6
+
7
+ # misc
8
+ .DS_Store
9
+ *.local
10
+
11
+ # debug
12
+ npm-debug.log*
13
+ yarn-debug.log*
14
+ yarn-error.log*