Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(postcss-normalize-url): inline is-absolute-url dep #1255

Merged
merged 1 commit into from Nov 30, 2021

Conversation

ludofischer
Copy link
Collaborator

is-absolute-url has become ESM only. It boils down to two
short regexes, so we can inline it.
The license is MIT which is the same as cssnano.

is-absolute-url has become ESM only. It boils down to two
short regexes, so we can inline it.
The license is MIT which is the same as cssnano.

const multiline = /\\[\r\n]/;
// eslint-disable-next-line no-useless-escape
const escapeChars = /([\s\(\)"'])/g;

// Scheme: https://tools.ietf.org/html/rfc3986#section-3.1
// Absolute URL: https://tools.ietf.org/html/rfc3986#section-4.3
const ABSOLUTE_URL_REGEX = /^[a-zA-Z][a-zA-Z\d+\-.]*?:/;
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The regexes are simple and I could not see any vulnerabilities reports or significant changes in the last two years.

@ludofischer ludofischer merged commit a4267de into master Nov 30, 2021
@ludofischer ludofischer deleted the remove-is-absolute-url branch November 30, 2021 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants