File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -85,6 +85,9 @@ import {
8585Explore the predefined templates for various configurations in the [ /templates] ( /templates ) directory. These templates provide quick-start setups for different environments.
8686
8787** [ /templates/typescript_react_stylex.template] ( /templates/typescript_react_stylex.template ) ** <br />
88+ ** [ /templates/typescript_react.template] ( /templates/typescript_react.template ) ** <br />
89+ ** [ /templates/typescript.template] ( /templates/typescript.template ) ** <br />
90+ ** [ /templates/base.template] ( /templates/base.template ) ** <br />
8891
8992## Getting Started
9093
@@ -108,6 +111,12 @@ Use the `cp` command to copy it into your project as `/babel.config.js`:
108111
109112``` bash
110113cp ./node_modules/@premierstacks/babel-stack/templates/typescript_react_stylex.template ./babel.config.js
114+ # or
115+ cp ./node_modules/@premierstacks/babel-stack/templates/typescript_react.template ./babel.config.js
116+ # or
117+ cp ./node_modules/@premierstacks/babel-stack/templates/typescript.template ./babel.config.js
118+ # or
119+ cp ./node_modules/@premierstacks/babel-stack/templates/base.template ./babel.config.js
111120```
112121
113122** 4. CLI**
Original file line number Diff line number Diff line change 3131 },
3232 "repository" : " github:premierstacks/babel-stack" ,
3333 "dependencies" : {
34- "@babel/core" : " ^7.26" ,
35- "@babel/preset-env" : " ^7.26" ,
36- "@babel/preset-react" : " ^7.26" ,
37- "@babel/preset-typescript" : " ^7.27" ,
38- "@stylexjs/babel-plugin" : " ^0.11 " ,
39- "core-js" : " ^3.41"
34+ "@babel/core" : " ^7.26.10 " ,
35+ "@babel/preset-env" : " ^7.26.9 " ,
36+ "@babel/preset-react" : " ^7.26.3 " ,
37+ "@babel/preset-typescript" : " ^7.27.0 " ,
38+ "@stylexjs/babel-plugin" : " ^0.12.0 " ,
39+ "core-js" : " ^3.41.0 "
4040 },
4141 "devDependencies" : {
4242 "@premierstacks/eslint-stack" : " github:premierstacks/eslint-stack#semver:^2.0" ,
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ export function createBabelConfigBase() {
2525 modules : false ,
2626 useBuiltIns : 'entry' ,
2727 corejs : {
28- version : '3.41' ,
28+ version : '3.41.0 ' ,
2929 proposals : false ,
3030 } ,
3131 } ,
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ export function createBabelConfigTypescriptReact() {
1818}
1919
2020export function applyBabelPresetReact ( config ) {
21- config . presets = config . presets || [ ] ;
21+ config . presets = config . presets ?? [ ] ;
2222
2323 config . presets . push ( [
2424 '@babel/preset-react' ,
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ export function createBabelConfigTypescriptReactStylex() {
1818}
1919
2020export function applyBabelPluginStylex ( config ) {
21- config . plugins = config . plugins || [ ] ;
21+ config . plugins = config . plugins ?? [ ] ;
2222
2323 config . plugins . push ( [
2424 '@stylexjs/babel-plugin' ,
Original file line number Diff line number Diff line change 1414import { createBabelConfigBase } from './base.js' ;
1515
1616export function applyBabelPresetTypescript ( config ) {
17- config . presets = config . presets || [ ] ;
17+ config . presets = config . presets ?? [ ] ;
1818
1919 config . presets . push ( [ '@babel/preset-typescript' , { } ] ) ;
2020
Original file line number Diff line number Diff line change 1+ import { createBabelConfigBase } from '@premierstacks/babel-stack';
2+
3+ export default createBabelConfigBase();
Original file line number Diff line number Diff line change 1+ import { createBabelConfigTypescript } from '@premierstacks/babel-stack';
2+
3+ export default createBabelConfigTypescript();
Original file line number Diff line number Diff line change 1+ import { createBabelConfigTypescriptReact } from '@premierstacks/babel-stack';
2+
3+ export default createBabelConfigTypescriptReact();
You can’t perform that action at this time.
0 commit comments