Skip to content

Commit

Permalink
feat(babel): add .cts, .mts to extension list (#1268)
Browse files Browse the repository at this point in the history
* feat(babel): add .cts, .mts to extension list

* chore: fix eslint error

* chore: changeset

---------

Co-authored-by: Anton Evzhakov <anton@evz.name>
  • Loading branch information
chentsulin and Anber committed Jul 11, 2023
1 parent 093cd57 commit 418e40a
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/new-gorillas-shake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@linaria/babel-preset': patch
---

Support for .cts/.mts files
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,17 @@ export default function loadLinariaOptions(
const options = {
displayName: false,
evaluate: true,
extensions: ['.cjs', '.json', '.js', '.jsx', '.mjs', '.ts', '.tsx'],
extensions: [
'.cjs',
'.cts',
'.json',
'.js',
'.jsx',
'.mjs',
'.mts',
'.ts',
'.tsx',
],
rules: rules ?? [
{
action: require.resolve('@linaria/shaker'),
Expand Down

0 comments on commit 418e40a

Please sign in to comment.