About

Detergent is a tool to prepare a text for pasting into HTML.

The main idea is, we need a program which, on default settings and with the least effort will make any text safe and optimal for pasting into HTML.

Text on web pages and email templates should look at its best:

These requirements are quite universal, and default settings of Detergent.io are aiming precisely at them.

Alternatively, Detergent can be used to strip HTML and prepare a text for non-HTML uses, for example, pasting into PSD or Sketch design files.

Architecture

Conceptually, this web page, detergent.io, is separate from its API, an Open Source npm package detergent detergent (npm page / monorepo).

Detergent-the-npm-package is separate from Detergent.io (this website) to allow other people to use Detergent in their programs, websites, Gulp tasks and everywhere else.

For the same reasons, all the major functions in the API are also separated into separate npm packages:

there are few more, but above are the main ones.

The main features of detergent.js, our API:

The main features of this web app

Main competition

There are no programs on the market comparable to Detergent.

he.js package is used by Detergent — it's driving the Detergent's HTML-encoding.

Email On Acid Character Converter is way inferior to he.js — to start with, it will neither remove invisible characters from text nor encode them. It's UI sucks, and it's ridden with marketing lead-gen.

Typograf (app/package) seems at first glance like a comparable app, but it's aimed at text preparation for web pages in the Russian language. Typograf's UI has English switch, but it has just a basic set of rules for n/m dashes and apostrophes. Typograf can't be used as an encoding tool either — £ is not even encoded, for example. Typograf's UI could be improved speaking mildly; it's got 97 settings with no filtration what is applicable for a given input, all hidden in the sidebar and not quite user-friendly.

Detergent Email on Acid Character Converter he.js Typograf
Encodes using named HTML entities (£) instead of numeric (£) so that you can read and understand your text after encoding
Will recognise named HTML entities which are not supported on email ESP's and will fall back to numeric
Input and output on the same screen, instantly
Removes invisible characters ❌ (silently skips) ❌ (only encodes)
Fixes English style partially
HTML tag-aware with granular tag whitelisting
Optionally skips encoding non-Latin characters
Prevents widow words
Recognises and granularly strips/skips HTML tags
Campaign-code (ESP-tags) friendly
API with its unit tests available publicly for inspection
Free, non-profit and Open Source API as an npm library

MIT License

Copyright (c) 2015–2019 Roy Revelt and other contributors

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Contacts

Detergent.io and Detergent.js were created and are maintained by Codsen Ltd.

Please report anything wrong you see on the UI or request new features by emailing roy@codsen.com or tweeting Roy @revelto

If you see anything wrong with any of the packages, raise an issue on GitLab, on our monorepository