Skip to content

Commit

Permalink
feat!: add css imports to cjs files (#1101)
Browse files Browse the repository at this point in the history
  • Loading branch information
amje committed Feb 6, 2024
1 parent ecdd1aa commit f10d616
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,7 @@ function compileTs(modules = false) {
'!src/**/*.test.{ts,tsx}',
'!src/**/__snapshots__/**/*',
])
.pipe(
replace(/import '.+\.scss';/g, (match) =>
modules ? match.replace('.scss', '.css') : '',
),
)
.pipe(replace(/(import.+)\.scss/g, '$1.css'))
.pipe(tsProject())
.pipe(dest(path.resolve(BUILD_DIR, modules ? 'esm' : 'cjs')));
}
Expand Down

0 comments on commit f10d616

Please sign in to comment.