Skip to content

Commit

Permalink
fix(#593): properly resolve the path to webpack loaders
Browse files Browse the repository at this point in the history
  • Loading branch information
m5r authored Dec 14, 2023
1 parent 9333440 commit 0c015f9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib/compilation/package-lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const { info, warn, error } = require('../log');

module.exports = (pathToProject, entry, baseEslintPath, options = {}) => {
const baseEslintConfig = fsUtils.readJson(baseEslintPath);

const directoryContainingEntry = path.dirname(entry);
const libName = path.basename(directoryContainingEntry);
info(`Packaging ${libName}`);
Expand Down Expand Up @@ -59,7 +59,7 @@ module.exports = (pathToProject, entry, baseEslintPath, options = {}) => {
{
enforce: 'pre',
test: /\.js$/,
loader: 'eslint-loader',
loader: require.resolve('eslint-loader'),
exclude: /node_modules/,
options: {
baseConfig: baseEslintConfig,
Expand All @@ -85,7 +85,7 @@ module.exports = (pathToProject, entry, baseEslintPath, options = {}) => {
if (err.details) {
error(err.details);
}

return reject(err);
}

Expand Down

0 comments on commit 0c015f9

Please sign in to comment.