@quilted/create 0.1.55 → 0.1.56

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @quilted/create
2
2
 
3
+ ## 0.1.56
4
+
5
+ ### Patch Changes
6
+
7
+ - [`b26de13b`](https://github.com/lemonmade/quilt/commit/b26de13b89f8433479f0d7931e5dcf1a381bb6c6) Thanks [@lemonmade](https://github.com/lemonmade)! - Add side effects to app templates
8
+
9
+ - [`96e837ee`](https://github.com/lemonmade/quilt/commit/96e837ee04f689898386891a926724597cf96937) Thanks [@lemonmade](https://github.com/lemonmade)! - Fix empty app template
10
+
3
11
  ## 0.1.55
4
12
 
5
13
  ### Patch Changes
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@quilted/create",
3
3
  "type": "module",
4
- "version": "0.1.55",
4
+ "version": "0.1.56",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
@@ -15,9 +15,10 @@
15
15
  "react": "npm:@quilted/react@^18.2.0",
16
16
  "react-dom": "npm:@quilted/react-dom@^18.2.0"
17
17
  },
18
- "eslintConfig": {
19
- "extends": "@quilted/eslint-config/app"
20
- },
18
+ "sideEffects": [
19
+ "*.css",
20
+ "browser.tsx"
21
+ ],
21
22
  "browserslist": {
22
23
  "defaults": [
23
24
  "extends @quilted/browserslist-config/defaults"
@@ -28,5 +29,8 @@
28
29
  "evergreen": [
29
30
  "extends @quilted/browserslist-config/evergreen"
30
31
  ]
32
+ },
33
+ "eslintConfig": {
34
+ "extends": "@quilted/eslint-config/app"
31
35
  }
32
36
  }
@@ -0,0 +1,7 @@
1
+ import {hydrateRoot} from 'react-dom/client';
2
+
3
+ import App from './App.tsx';
4
+
5
+ const element = document.querySelector('#app')!;
6
+
7
+ hydrateRoot(element, <App />);
@@ -8,15 +8,17 @@
8
8
  },
9
9
  "dependencies": {},
10
10
  "devDependencies": {
11
+ "@quilted/quilt": "^0.5.0",
11
12
  "@types/react": "^18.0.0",
12
13
  "@types/react-dom": "^18.0.0",
13
14
  "preact": "^10.13.0",
14
15
  "react": "npm:@quilted/react@^18.2.0",
15
16
  "react-dom": "npm:@quilted/react-dom@^18.2.0"
16
17
  },
17
- "eslintConfig": {
18
- "extends": "@quilted/eslint-config/app"
19
- },
18
+ "sideEffects": [
19
+ "*.css",
20
+ "browser.tsx"
21
+ ],
20
22
  "browserslist": {
21
23
  "defaults": [
22
24
  "extends @quilted/browserslist-config/defaults"
@@ -27,5 +29,8 @@
27
29
  "evergreen": [
28
30
  "extends @quilted/browserslist-config/evergreen"
29
31
  ]
32
+ },
33
+ "eslintConfig": {
34
+ "extends": "@quilted/eslint-config/app"
30
35
  }
31
36
  }
@@ -1,5 +1,14 @@
1
1
  import {createProject, quiltApp} from '@quilted/craft';
2
2
 
3
3
  export default createProject((project) => {
4
- project.use(quiltApp());
4
+ project.use(
5
+ quiltApp({
6
+ browser: {
7
+ entry: './browser.tsx',
8
+ },
9
+ server: {
10
+ entry: './server.tsx',
11
+ },
12
+ }),
13
+ );
5
14
  });
@@ -0,0 +1,19 @@
1
+ import {createRequestRouter, createServerRender} from '@quilted/quilt/server';
2
+ import {createBrowserAssets} from '@quilted/quilt/magic/assets';
3
+
4
+ const router = createRequestRouter();
5
+
6
+ // For all GET requests, render our React application.
7
+ router.get(
8
+ createServerRender(
9
+ async () => {
10
+ const {default: App} = await import('./App.tsx');
11
+ return <App />;
12
+ },
13
+ {
14
+ assets: createBrowserAssets(),
15
+ },
16
+ ),
17
+ );
18
+
19
+ export default router;
@@ -18,13 +18,10 @@
18
18
  "react": "npm:@quilted/react@^18.2.0",
19
19
  "react-dom": "npm:@quilted/react-dom@^18.2.0"
20
20
  },
21
- "eslintConfig": {
22
- "extends": "@quilted/eslint-config/app",
23
- "ignorePatterns": [
24
- "*.graphql.d.ts",
25
- "graphql/schema.ts"
26
- ]
27
- },
21
+ "sideEffects": [
22
+ "*.css",
23
+ "browser.tsx"
24
+ ],
28
25
  "browserslist": {
29
26
  "defaults": [
30
27
  "extends @quilted/browserslist-config/defaults"
@@ -35,5 +32,12 @@
35
32
  "evergreen": [
36
33
  "extends @quilted/browserslist-config/evergreen"
37
34
  ]
35
+ },
36
+ "eslintConfig": {
37
+ "extends": "@quilted/eslint-config/app",
38
+ "ignorePatterns": [
39
+ "*.graphql.d.ts",
40
+ "graphql/schema.ts"
41
+ ]
38
42
  }
39
43
  }
@@ -15,9 +15,9 @@
15
15
  "react": "npm:@quilted/react@^18.2.0",
16
16
  "react-dom": "npm:@quilted/react-dom@^18.2.0"
17
17
  },
18
- "eslintConfig": {
19
- "extends": "@quilted/eslint-config/app"
20
- },
18
+ "sideEffects": [
19
+ "*.css"
20
+ ],
21
21
  "browserslist": {
22
22
  "defaults": [
23
23
  "extends @quilted/browserslist-config/defaults"
@@ -28,5 +28,8 @@
28
28
  "evergreen": [
29
29
  "extends @quilted/browserslist-config/evergreen"
30
30
  ]
31
+ },
32
+ "eslintConfig": {
33
+ "extends": "@quilted/eslint-config/app"
31
34
  }
32
35
  }