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

Support per-website/element writeas settings #156

Open
stephenh opened this issue Nov 28, 2016 · 1 comment
Open

Support per-website/element writeas settings #156

stephenh opened this issue Nov 28, 2016 · 1 comment

Comments

@stephenh
Copy link

I was following the thread about using wasavi in gmail, and that using writeas=textAndBreak will make it work. That seems to work really well and is great.

I've put writeas=textAndBreak into my exrc, but I'm anticipating that certain websites will need certain writeas...e.g. gmail may want textAndBreak, but github may work better with html, etc.

@akahuku
Copy link
Owner

akahuku commented Feb 7, 2017

I think this is a very important issue, so I'd like to change writeas as follows:

  • Allow writeas to assign a string that can be parsed as JSON
  • JSON defines the value of writeas for each site

writeas will be set in your exrc as follows:

set writeas='{ \
  /* Give a site a simple writeas value */ \
  "http://example.com/*": "text", \
  /* Give the site an array of CSS selector and writeas pair */ \
  "http://exmaple.net/*": [ \
    { \
      "selector": "#element-id", \
      "writeas": "textAndBreak" \
    } \
  } \
}'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants