Last active
July 1, 2022 23:03
-
-
Save Shelob9/016417af2a487c34a61db61953040e91 to your computer and use it in GitHub Desktop.
Getting Typescript working with Laravel Vite. https://laravel.com/docs/9.x/frontend#using-vue-react https://twitter.com/Josh412/status/1543003505371353089
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const defaultTheme = require('tailwindcss/defaultTheme'); | |
/** @type {import('tailwindcss').Config} */ | |
module.exports = { | |
content: [ | |
'./vendor/laravel/framework/src/Illuminate/Pagination/resources/views/*.blade.php', | |
'./storage/framework/views/*.php', | |
'./resources/views/**/*.blade.php', | |
'./resources/js/**/*.jsx', | |
//NEW - Check tsx files for tailwind styles | |
'./resources/js/**/*.tsx', | |
], | |
theme: { | |
extend: { | |
fontFamily: { | |
sans: ['Nunito', ...defaultTheme.fontFamily.sans], | |
}, | |
}, | |
}, | |
plugins: [require('@tailwindcss/forms')], | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"compilerOptions": { | |
"target": "ESNext", | |
"lib": ["DOM", "DOM.Iterable", "ESNext"], | |
"allowJs": false, | |
"skipLibCheck": false, | |
"esModuleInterop": true, | |
"allowSyntheticDefaultImports": true, | |
"strict": true, | |
"forceConsistentCasingInFileNames": true, | |
"module": "ESNext", | |
"moduleResolution": "Node", | |
"resolveJsonModule": true, | |
"isolatedModules": true, | |
"noEmit": true, | |
"jsx": "react" | |
}, | |
"include": ["./resources/js/*"], | |
"exclude": [ | |
"**/*.test.ts", | |
"**/*.test.tsx", | |
"**/*.test.js", | |
"**/*.test.jsx" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"compilerOptions": { | |
"composite": true, | |
"module": "esnext", | |
"moduleResolution": "node" | |
}, | |
"include": ["vite.config.ts"] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment