Possible to use with Laravel and typescript?
See original GitHub issueI have tried many setups but these warnings when using with Laravel project running yarn dev and this error:
app.js:151605 Uncaught TypeError: twin_macro__WEBPACK_IMPORTED_MODULE_1___default.a.div is not a function
Critical dependency: require function is used in a way in which dependencies cannot be statically extracted
@ ./node_modules/twin.macro/macro.js
@ ./resources/ts/components/Calender.tsx
@ ./resources/ts/app.ts
@ multi ./resources/ts/app.ts ./resources/css/app.css
WARNING in ./node_modules/twin.macro/macro.js 41:61-80
Critical dependency: the request of a dependency is an expression
@ ./resources/ts/components/Calender.tsx
@ ./resources/ts/app.ts
@ multi ./resources/ts/app.ts ./resources/css/app.css
WARNING in ./node_modules/import-fresh/index.js 31:31-48
Critical dependency: the request of a dependency is an expression
@ ./node_modules/babel-plugin-macros/node_modules/cosmiconfig/dist/loaders.js
@ ./node_modules/babel-plugin-macros/node_modules/cosmiconfig/dist/index.js
@ ./node_modules/babel-plugin-macros/dist/index.js
@ ./node_modules/twin.macro/macro.js
@ ./resources/ts/components/Calender.tsx
@ ./resources/ts/app.ts
@ multi ./resources/ts/app.ts ./resources/css/app.css```
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Typescript with Laravel
TypeScript provides optional static typing, which lets you structure and validate your code at the compilation stage. It also brings the IDE ...
Read more >TypeScript with Laravel Mix - Sebastian De Deyne
TypeScript with Laravel Mix · 1) Install The Necessary Dependencies · 2) Configure TypeScript · 3) Configure Laravel Mix · 4) Write Some...
Read more >How to install & use ReactJS in TypeScript with Laravel 8 ...
We can start by scaffolding a new laravel app using the command: laravel new larareacts. Install typescript globally on your local machine:.
Read more >Laravel mix TypeScript setup - Floyk
Laravel mix TypeScript setup · 1. Step - create tsconfig.json · 2. Step - create app.ts and config webpack.mix.js · 3. Install ts-loader...
Read more >How to use Typescript in Laravel Project with Vue as frontend?
How to use Typescript in Laravel Project with Vue as frontend? · Initialize your project · Add Typescript Support · Finally build the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Cool thanks for your help and the awesome library 😃 Yeah I’m surprised Laravel hasn’t switch to use babel or added a way to do it, I guess they don’t have enough typescript users yet.
I think the problem is babel macros do not work with ts-loader so I got it working with laravel-mix using babel-loader instead by using laravel-mix-react-typescript-extension.