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

Add tests for awesome mailto: links #16

Closed
2 of 3 tasks
fulldecent opened this issue Mar 20, 2017 · 15 comments
Closed
2 of 3 tasks

Add tests for awesome mailto: links #16

fulldecent opened this issue Mar 20, 2017 · 15 comments

Comments

@fulldecent
Copy link
Owner

fulldecent commented Mar 20, 2017

Discussion

This is a not-awesome mailto link:

<a href="mailto:support@pacificmedicaltraining.com">Email us</a>

This is an awesome link:

<a href="mailto:support@pacificmedicaltraining.com?subject=Signing up&amp;body=Hello,\nI'd like to sign up for your course, can you please send me more information.">Email us</a>

We should use awesome links as psychological warfare against users. Users will send us emails with stupid or annoying emails that we don't want. So instead we prefill the email with the message we want to receive. It takes active cognitive effort for the user to put in their unwanted message.

You can make these with a tool like:

http://www.mailto.co.uk/

Actually that link does not work with /n, please recommend a better tool.

Also see http://stackoverflow.com/a/41365892/300224

Work plan

  • Create extension for html-proofer that checks for awesome mailto links.
  • I will publish it in a new repo.
  • Integrate it into this project.
@ilyalyo
Copy link
Contributor

ilyalyo commented Mar 28, 2017

@fulldecent this tool:
http://marcwitteveen.com/mailtogenerator/
can handle new lines.

@fulldecent
Copy link
Owner Author

Nice, that tool works great.

@ilyalyo
Copy link
Contributor

ilyalyo commented Mar 28, 2017

@fulldecent just to clarify, it's not a PR to public html-proofer repository, it's going to be a private extension?

@fulldecent
Copy link
Owner Author

Yes, this is correct. We will follow the process here https://github.com/gjtorikian/html-proofer#custom-tests

I do not think html-proofer is interested to include that extension in its normal product.

We can do that work here

https://github.com/fulldecent/html-proofer-mailto-awesome

I suppose that you can set it up as a gem project. Then I will publish the gem to ruby gems. Then we will import it to https://github.com/fulldecent/lightning-sites in the test script.

@ilyalyo
Copy link
Contributor

ilyalyo commented Mar 30, 2017

Added PR with extension: fulldecent/html-proofer-mailto_awesome#1
May be it would be better to make a fork?

@fulldecent
Copy link
Owner Author

I think the extension can be done more modularly. I have asked for help at gjtorikian/html-proofer#415

@fulldecent
Copy link
Owner Author

Please use this approach: https://github.com/gjtorikian/html-proofer#custom-tests

@ilyalyo
Copy link
Contributor

ilyalyo commented May 1, 2017

This is have it's done now.
What do you think if we will make a fork and add all custom futures in it and use in our travis?

@fulldecent
Copy link
Owner Author

This should not be a fork. Here is the repository for this module:

https://github.com/fulldecent/html-proofer-mailto-awesome

We just want a simple class using the example in https://github.com/gjtorikian/html-proofer#custom-tests

Then I can publish as a gem. Then we can pull this gem from lightning-sites and call that custom class when we call html-proofer using Ruby.

@ilyalyo
Copy link
Contributor

ilyalyo commented May 2, 2017

I pushed mailto-awesome class and gemspec into https://github.com/fulldecent/html-proofer-mailto-awesome

@fulldecent
Copy link
Owner Author

This looks good so far. Please update this file I started: https://github.com/fulldecent/html-proofer-mailto-awesome

@fulldecent
Copy link
Owner Author

@fulldecent
Copy link
Owner Author

Ready to use html-proofer-mailto_awesome from lightning-sites

@ilyalyo
Copy link
Contributor

ilyalyo commented May 16, 2017

I updated mailto_awesom, so it can be run optionaly: added option check_mailto_awesome
fulldecent/html-proofer-mailto_awesome#8
and added this check to lighting sites:
fulldecent/lightning-sites#17

@fulldecent
Copy link
Owner Author

Fixed in fa757fe

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

No branches or pull requests

2 participants