create-application-template 2.3.3 → 2.4.1-beta.0

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/.babelrc CHANGED
@@ -14,11 +14,14 @@
14
14
  "@babel/plugin-transform-runtime",
15
15
  {
16
16
  "regenerator": true
17
- },
18
- "react-refresh/babel"
19
- ]
17
+ }
18
+ ],
19
+ "babel-plugin-react-compiler"
20
20
  ],
21
21
  "env": {
22
+ "development": {
23
+ "plugins": ["react-refresh/babel"]
24
+ },
22
25
  "test": {
23
26
  // to mock webpack's require.context in jest
24
27
  "plugins": ["transform-require-context"]
package/README.md CHANGED
@@ -14,7 +14,11 @@ See the template running live [here](https://www.createapplicationtemplate.com/)
14
14
  ## installation
15
15
  first install globally
16
16
  ```
17
- npm install -g create-application-template
17
+ npm install -g create-application-template@latest
18
+ ```
19
+ _or_
20
+ ```
21
+ npm install -g create-application-template@beta
18
22
  ```
19
23
 
20
24
  then create your project
@@ -22,6 +26,13 @@ then create your project
22
26
  npx create-application-template --name={my-project}
23
27
  ```
24
28
 
29
+ ## new on BETA version 🚀
30
+ beta upgrades to React 19 with [React Compiler](https://react.dev/learn/react-compiler/introduction) opt-in
31
+
32
+ this version takes advantage of the React Compiler's automatic optimization
33
+
34
+ it also includes the React Compiler's ESLint integretion
35
+
25
36
  ## usage
26
37
  webpack is used for code bundling and the development server
27
38
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-application-template",
3
- "version": "2.3.3",
3
+ "version": "2.4.1-beta.0",
4
4
  "description": "provides a configured application template for you to build upon",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -50,8 +50,8 @@
50
50
  "dotenv-flow": "4.1.0",
51
51
  "husky": "9.1.7",
52
52
  "polished": "4.3.1",
53
- "react": "18.3.1",
54
- "react-dom": "18.3.1",
53
+ "react": "19.1.1",
54
+ "react-dom": "19.1.1",
55
55
  "styled-components": "6.1.15",
56
56
  "yargs": "17.7.2"
57
57
  },
@@ -68,14 +68,15 @@
68
68
  "@testing-library/user-event": "14.6.1",
69
69
  "@types/jest": "29.5.14",
70
70
  "@types/node": "20.12.12",
71
- "@types/react": "18.3.2",
72
- "@types/react-dom": "18.3.0",
71
+ "@types/react": "19.1.13",
72
+ "@types/react-dom": "19.1.9",
73
73
  "@types/styled-components": "5.1.34",
74
74
  "@types/webpack-env": "1.18.8",
75
75
  "@typescript-eslint/eslint-plugin": "6.5.0",
76
76
  "@typescript-eslint/parser": "6.5.0",
77
77
  "babel-jest": "29.7.0",
78
78
  "babel-loader": "10.0.0",
79
+ "babel-plugin-react-compiler": "19.1.0-rc.3",
79
80
  "babel-plugin-styled-components": "2.1.4",
80
81
  "babel-plugin-transform-require-context": "0.1.1",
81
82
  "case-sensitive-paths-webpack-plugin": "2.4.0",
@@ -90,7 +91,7 @@
90
91
  "eslint-plugin-import": "2.31.0",
91
92
  "eslint-plugin-jsx-a11y": "6.10.2",
92
93
  "eslint-plugin-react": "7.37.4",
93
- "eslint-plugin-react-hooks": "5.2.0",
94
+ "eslint-plugin-react-hooks": "6.0.0-rc.2",
94
95
  "html-webpack-plugin": "5.6.3",
95
96
  "identity-obj-proxy": "3.0.0",
96
97
  "jest": "29.7.0",
@@ -9,19 +9,19 @@ import logo from '../assets/logo.svg'
9
9
  import { Counter } from './Counter'
10
10
  import { Typewriter } from './Typewriter'
11
11
 
12
- export const App: FC = () => {
13
- const TemplateLink: FC = () => {
14
- return (
15
- <app.StyledLink
16
- href='https://www.npmjs.com/package/create-application-template'
17
- rel='noreferrer'
18
- target='_blank'
19
- >
20
- here
21
- </app.StyledLink>
22
- )
23
- }
12
+ const TemplateLink: FC = () => {
13
+ return (
14
+ <app.StyledLink
15
+ href='https://www.npmjs.com/package/create-application-template'
16
+ rel='noreferrer'
17
+ target='_blank'
18
+ >
19
+ here
20
+ </app.StyledLink>
21
+ )
22
+ }
24
23
 
24
+ export const App: FC = () => {
25
25
  return (
26
26
  <ThemeProvider theme={theme}>
27
27
  <GlobalStyles />
@@ -28,8 +28,12 @@ export const Typewriter: FC<
28
28
  // B) this triggers the typing animation effect to restart with the new text
29
29
 
30
30
  useEffect(() => { // A
31
- setDisplayedText('')
32
- setCurrentIndex(0)
31
+ const timeoutIdInit = setTimeout(() => {
32
+ setDisplayedText('')
33
+ setCurrentIndex(0)
34
+ }, 0)
35
+
36
+ return () => clearTimeout(timeoutIdInit)
33
37
  }, [text])
34
38
 
35
39
  useEffect(() => { // B