feat(pluginutils): normalizePath#550
Merged
shellscape merged 4 commits intorollup:masterfrom Sep 10, 2020
Merged
Conversation
9 tasks
NotWoods
reviewed
Aug 20, 2020
Member
NotWoods
left a comment
There was a problem hiding this comment.
plugin-typescript has a similar function to normalize the path. Can we make that its own pluginUtil?
Collaborator
|
@eight04 please take a look at the last comment |
Contributor
Author
|
How does typescript plugin use the normalization? If it also relates to picomatch then we can add a Or, do you want a small util like this: export function normalizePathSep(path) {
return path
.split(sep)
.join('/');
} |
Member
|
Just a small util like that, although I prefer the implementation in the typescript plugin as it uses constants from node. |
eight04
commented
Sep 10, 2020
| leave(node) { | ||
| if (node.scope) scope = scope.parent; | ||
| } | ||
| }, |
Contributor
Author
There was a problem hiding this comment.
I think these were added by prettier.
NotWoods
approved these changes
Sep 10, 2020
pnevares
approved these changes
Sep 10, 2020
Collaborator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Rollup Plugin Name:
pluginutilsThis PR contains:
Are tests included?
Breaking Changes?
If yes, then include "BREAKING CHANGES:" in the first commit message body, followed by a description of what is breaking.
List any relevant issue numbers:
Description
This PR includes:
normalizePath.path.resolvecreates patterns including backward slash\. This patch adds a normalization similar tocreateFilter:plugins/packages/pluginutils/src/createFilter.ts
Lines 15 to 17 in 55a9cb2