hashdown 1.0.6 copy "hashdown: ^1.0.6" to clipboard
hashdown: ^1.0.6 copied to clipboard

outdatedDart 1 only

Hashdown is an file/text-to-text encoding scheme designed for safe and compact data sharing

Hashdown #

Hashdown is an online tool to convert text into a format that's easier and safer for sharing

http://www.hashdown.net/edit.html

It supports 3 different encoding modes

Hashdown link convert text into url hash

Example:
http://www.hashdown.net/#SGFzaERvd24gTGluayBpcyBBd2Vzb21l

Why?

Of course, you can write things on blog and share the link. But Hashdown link does it in a very different way

  • The encoding and decoding are 100% done in client side javascript, our server never know your text. the url hash (what's after #) is never sent to the network.
  • When the server is down, you can still decode the content from the url if you can find any Hashdown mirror site or an offline version of Hashdown tool.
  • You can use a password to protect your content.

Url Shortener

Url shortener works great with Hashdown link, like this: http://goo.gl/Oz9MJu

But if the url shortener service is shutdown or blocked by firewall, people will no longer be able to access it.

Hashdown Base2e15 #

Base2e15 convert text to unicode characters, each unicode character represents 15 bits of data.

Since Hashdown supports compression, it allows you to store more text in limited number of characters

Sample Plain Text ( 322 characters )

In URIs a hashmark # introduces the optional fragment near the end of the URL. The generic RFC 3986 syntax for URIs also allows an optional query part introduced by a question mark ?. In URIs with a query and a fragment, the fragment follows the query. Query parts depend on the URI scheme and are evaluated by the server.

Convert to Base2e15 ( 114 characters )

蜵웦孴쮨廳擽땧䅧橔䑚쌳唜峇땢榃堻嗐歱揘芊쁷䌷䬕䆪㽍蜞芻䂜뗊俅뀾塙륡곻摡壱䉌捃玺뫂쑽릆샱糓䀡윷㚂䰒㾎렷䝿닸孔쯝禑揩㦊莛蔍嬚쥎䕾涩屇灞䣽浚껲净꼏掸煜㳌낣췹哈潶㘁唺캮㳳萯德왔뒉䜠澎㴺데瀊킊炛㴕渄味䈥폺뙉臋艺몪爱닄焍薍䩨感휧夻프쨭㿊줘㐀

Hashdown Tadpole Code #

Tadpole Code convert text to unicode combining characters, which is saves all your visual space by combining everything into "single" character.

Convert above sample text to Tadpole Code:

/゙ًًًًًًًًًًًًًًًًًًًًًًًٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٌٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍٍََََََََََََََََََََََََََََُُُُُُُُُُُُُُُُُُُُُُُُُُُُِِِِِِِِِِِِِِِِِِِِِِِِِِّّّّّّّّّّّّّّّّّّّّّّّّّّّّْْْْْْْْْْْْْْْْْْْْْْْْْْْْٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٰٕٕٜ۪ٕ۪۪ٕ۪ٕ۪۪۪ٜٕٜٜٕ۪۪۪۪۪ٕٕ۪۪ٕٕٕ۪۪۪ٕ۪ٜٜٕ۪ٜٕٕ۪ٕ۪۪۪۪ٕ۪ٜٕٕٕٜ۪ٜٕٕ۪ٕٕ۪۪ٜ۪ٜٜ۪۪ٜٜٜٜٜ۪ٕٜٕٜۤٓٔٔۤٔۤٓ۠ٔٔٓٔ۠ۤ۠ۤۤۤ۠۠۠ۤ۠ٓ۠ۤٓۤ۠ۤۤ۠ۤٔۤۤ۠ۤۤ۠ٓٓۤ۠ٓۤ۠ٔۤٓٓٓ۠۠۠ۤٔ۠۠ٓٔٔٓٓ۠ٓ۠ۤٓٔٔ۠ۤٓ۠ٓٓۤۤٔۤ۠ۤٓٓ۠ۤ۠ٔ۠ٓۤۤٓ ( It's actually **426** characters!! )

Hashdown Shadow Code #

Shadow Code convert text to ASCII control code, which is invisible in most browsers.

Sample Plain Text

Hello {ShadowCode}World

Convert to Shadow Code

Hello ‍‌‌‌​‍​‌‍World

The font compatibility of Shadow Code is not as good as Tadpole Code, and it's not suitable for encoding long string.

API #

API to encode and decode hashdown in javascript and dart code

javascript #

    <script src="http://www.hashdown.net/api.js"></script>
    <script>
      // simple encoding/decoding
      var encoded1 = $hashdown.encode('Hashdown is awesome');
      var decoded1 = $hashdown.decode(encoded1);

      // encoding with options
      var encoded2 = $hashdown.encode('Hashdown is awesome',{
        "codec" : $hashdown.BASE2E15,
        "markdown" : true,
        "protect" :  $hashdown.PROTECT_PASSWORD,
        "password" : "mypassword"
      });
      var decoded2 = $hashdown.decode(encoded2, 'mypassword').text;
    </script>

dart #

  import 'package:hashdown/hashdown.dart';

  void main() {
    // encode string to hashdown link
    String hashdownLink =
        Hashdown.encodeString('Hashdown is awesome', new HashdownOptions());
    
    // encode string to tadpole code
    String tadpolecode = Hashdown.encodeString(
        'Hashdown is awesome', new HashdownOptions()..codec = Hashdown.TADPOLE);
  }

Libraries used in Hashdown #

https://pub.dartlang.org/packages/lzma

https://github.com/chjj/marked

2
likes
0
pub points
25%
popularity

Publisher

unverified uploader

Hashdown is an file/text-to-text encoding scheme designed for safe and compact data sharing

Homepage

License

unknown (LICENSE)

Dependencies

base2e15, crypto, lzma

More

Packages that depend on hashdown