made with esnextbin
Created
April 3, 2016 19:03
-
-
Save terrysahaidak/24bc71240bdba3931a1505d1c71dc0d0 to your computer and use it in GitHub Desktop.
esnextbin sketch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>ESNextbin Sketch</title> | |
<!-- put additional styles and scripts here --> | |
</head> | |
<body> | |
<!-- put markup and other contents here --> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// write ES2015 code and import modules from npm | |
// and then press "Execute" to run your program | |
import showdown from 'showdown' | |
const md = ` | |
Кольцо **CUBE** из белого золота с паве из черных и белых бриллиантов.\n | |
68 бриллиантов Кр57 3/5 – _0,52 карата_.\n | |
52 черных бриллианта Кр57 – 0,41карата.\n | |
Белое золото – 7,44 гр. | |
` | |
const converter = new showdown.Converter() | |
const html = converter.makeHtml(md) | |
document.body.innerHTML = html | |
console.log(html) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "esnextbin-sketch", | |
"version": "0.0.0", | |
"dependencies": { | |
"showdown": "1.3.0" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var _showdown = require('showdown'); | |
var _showdown2 = _interopRequireDefault(_showdown); | |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | |
var md = '\nКольцо **CUBE** из белого золота с паве из черных и белых бриллиантов.\n\n68 бриллиантов Кр57 3/5 – _0,52 карата_.\n\n52 черных бриллианта Кр57 – 0,41карата.\n\nБелое золото – 7,44 гр.\n\n'; // write ES2015 code and import modules from npm | |
// and then press "Execute" to run your program | |
var converter = new _showdown2.default.Converter(); | |
var html = converter.makeHtml(md); | |
document.body.innerHTML = html; | |
console.log(html); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment