Add target blank option to auto link #105

merged 3 commits into from Mar 11, 2014


None yet
3 participants

eileencodes commented Dec 30, 2013

Although :target => "_blank" is an available option I'm proposing adding :target_blank => true to keep in line with the js version of twitter text option of targetBlank. This will make it easier for developers to move back and forth between the two libraries without having to look up documentation. This new option adds target="_blank" to all auto linked entities not just url entities (as in :url_target).

eileencodes added some commits Dec 29, 2013

add :target_blank option
Twitter text js has a targetBlank option. To make it
easier to go back and forth between twitter text js
and twitter text ruby add the target_blank option to
match targetBlank from js. Ensure that this target_blank
differs from url_target by adding "target='_blank'" to
all auto_linked entities.
add test for new :target_blank option
Ensure that all types of links are auto linked AND
target="_blank" is added too all these links.

yannp commented Feb 3, 2014



jakl commented Mar 11, 2014

Looks good and tests pass for me.

jakl added a commit that referenced this pull request Mar 11, 2014

Merge pull request #105 from eileencodes/add_target_blank_option_to_a…

Add target blank option to auto link

@jakl jakl merged commit 0d96e3d into twitter:master Mar 11, 2014

1 check failed

default The Travis CI build could not complete due to an error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment