Comments (4)
Hi!
I like the alternative you propose better than adding more and more properties on the options object itself.
It’s slightly weird that target
and rel
are on the root options object, if there’s also a linkProperties
or so. And which should get precedence if linkProperties.rel
is set?
And what name to use? Maybe properties
is fine?
One thing to think about: those properties need to be deep cloned, because rel
or className
could be arrays. And there are other values allowed.
Would you be interested in working on a PR?
Would be something like https://github.com/rehypejs/rehype-autolink-headings/blob/a37d231c4c0c29c6880d8e1b6842dfbd771027dc/lib/index.js#L21-L24, https://github.com/rehypejs/rehype-autolink-headings/blob/a37d231c4c0c29c6880d8e1b6842dfbd771027dc/lib/index.js#L108. With a default of {}
I think. And then rel
and target
are preferred over properties.rel
/properties.target
?
from rehype-external-links.
Hi! This was marked as ready to be worked on! Note that while this is ready to be worked on, nothing is said about priority: it may take a while for this to be solved.
Is this something you can and want to work on?
Team: please use the area/*
(to describe the scope of the change), platform/*
(if this is related to a specific one), and semver/*
and type/*
labels to annotate this. If this is first-timers friendly, add good first issue
and if this could use help, add help wanted
.
from rehype-external-links.
I don‘t think this is a good use of ARIA btw. Not only screen readers need to know where your link goes. Everyone does.
from rehype-external-links.
There's still no consensus on this, but I think I got the idea from these two sources:
https://it.wisc.edu/learn/make-it-accessible/develop-accessible-websites/when-to-open-links-in-a-new-tab/
https://www.digitala11y.com/external-links-in-or-out/
My bad for using a bad example -- it should really include the destination as recommended in the articles.
from rehype-external-links.
Related Issues (6)
- Change defaults to not add `target`, `rel` should just be `['nofollow']` HOT 2
- Add option to include relative links HOT 4
- feat: exclude certain links with a `no-external` attribute HOT 16
- The package in npm is not same with Github HOT 3
- Links to protocol-relative URLs are not marked rel=nofollow HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rehype-external-links.