Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vue-loader
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pi-plusplus
fork-from-github
vue-loader
Commits
3d07f818
Commit
3d07f818
authored
May 19, 2018
by
Evan You
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perf: avoid duplicate linting when used with eslint-loader
parent
aec11fcb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
pitcher.js
lib/loaders/pitcher.js
+9
-1
No files found.
lib/loaders/pitcher.js
View file @
3d07f818
...
...
@@ -10,7 +10,15 @@ module.exports = code => code
// and transform it into appropriate requests.
module
.
exports
.
pitch
=
function
(
remainingRequest
)
{
const
query
=
qs
.
parse
(
this
.
resourceQuery
.
slice
(
1
))
const
loaders
=
this
.
loaders
.
slice
(
1
)
// remove self
// if this is a language block request, remove eslint-loader to avoid
// duplicate linting.
const
loaders
=
query
.
type
?
this
.
loaders
.
filter
(
l
=>
!
/
(\/
|
\\
|@
)
eslint-loader/
.
test
(
l
.
path
))
:
this
.
loaders
// remove self
loaders
.
shift
()
// do not inject if user uses null-loader to void the type (#1239)
if
(
loaders
.
some
(
l
=>
/
(\/
|
\\
|@
)
null-loader/
.
test
(
l
.
path
)))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment