Skip to content

Commit

Permalink
Hardcode extension for now
Browse files Browse the repository at this point in the history
  • Loading branch information
askoufis committed Nov 27, 2023
1 parent 6101300 commit 7035010
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions packages/sku/config/webpack/utils/index.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
const loaders = require('./loaders');
const { resolvePackage } = require('./resolvePackage');
const { js, ts } = require('eslint-config-seek/extensions');

// TODO: Figure out a better way to share this config. This is currently copy-pasted from
// `eslint-config-seek`
const extensions = {
js: ['js', 'cjs', 'mjs', 'jsx'],
ts: ['ts', 'cts', 'mts', 'tsx'],
};

module.exports = {
...loaders,
resolvePackage,
TYPESCRIPT: new RegExp(`\.(${ts.join('|')})$`),
JAVASCRIPT: new RegExp(`\.(${js.join('|')})$`),
TYPESCRIPT: new RegExp(`\.(${extensions.ts.join('|')})$`),
JAVASCRIPT: new RegExp(`\.(${extensions.js.join('|')})$`),
LESS: /\.less$/,
IMAGE: [/\.bmp$/, /\.gif$/, /\.jpe?g$/, /\.png$/],
SVG: /\.svg$/,
Expand Down

0 comments on commit 7035010

Please sign in to comment.