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

no-empty-url: check urls from definitions #299

Merged
merged 1 commit into from
Oct 26, 2022
Merged

no-empty-url: check urls from definitions #299

merged 1 commit into from
Oct 26, 2022

Conversation

Xunnamius
Copy link
Contributor

@Xunnamius Xunnamius commented Oct 26, 2022

Initial checklist

  • I read the support docs
  • I read the contributing guide
  • I agree to follow the code of conduct
  • I searched issues and couldn’t find anything (or linked relevant results below)
  • If applicable, I’ve added docs and tests

Description of changes

First, thank you for remark and the unified ecosystem!

This is a small fix to allow remark-lint-no-empty-url to also consider the URLs of Definition nodes when linting. When I first used this rule, I assumed that, because of the name, it would apply to all URLs. However, after using remark-reference-links, any mistakenly empty URLs normally caught by this rule were transformed into mistakenly empty definitions that were no longer caught by this rule, which came as a surprise to me.

Along with updated tests and documentation, I'm currently using my forked version across several projects if you want to test it out real quick:

npm install --save-dev https://xunn.at/remark-lint-no-empty-url
npx remark -o --no-config --use remark-lint-no-empty-url file-with-empty-definition.md

@github-actions github-actions bot added the 👋 phase/new Post is being triaged automatically label Oct 26, 2022
@github-actions

This comment has been minimized.

@github-actions github-actions bot added 🤞 phase/open Post is being triaged manually and removed 👋 phase/new Post is being triaged automatically labels Oct 26, 2022
@codecov-commenter
Copy link

Codecov Report

Base: 100.00% // Head: 100.00% // No change to project coverage 👍

Coverage data is based on head (8f222f3) compared to base (6ca7eef).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #299   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           73        73           
  Lines         8475      8486   +11     
=========================================
+ Hits          8475      8486   +11     
Impacted Files Coverage Δ
packages/remark-lint-no-empty-url/index.js 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@wooorm wooorm changed the title no-empty-url: consider urls from definition nodes no-empty-url: check urls from definitions Oct 26, 2022
@wooorm wooorm merged commit 5bdc23b into remarkjs:main Oct 26, 2022
@wooorm wooorm added 🦋 type/enhancement This is great to have 💪 phase/solved Post is done labels Oct 26, 2022
@github-actions

This comment has been minimized.

@wooorm
Copy link
Member

wooorm commented Oct 26, 2022

Thank you, good idea!!

@github-actions github-actions bot removed the 🤞 phase/open Post is being triaged manually label Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💪 phase/solved Post is done 🦋 type/enhancement This is great to have
Development

Successfully merging this pull request may close these issues.

3 participants