Comparing version 1.2.1 to 1.2.2
@@ -12,4 +12,5 @@ const transpileJSX = require('./lib/components'); | ||
const jsx = (input, config = {}) => { | ||
const { e, i, ias, ii } = makeMarkers({ | ||
const { e, ef, i, ias, ii } = makeMarkers({ | ||
e: /^ *export\s+(?:default\s+)?/mg, | ||
ef: /^ *export\s+{[^}]+}\s+from\s+(['"])(?:.+?)\1/mg, | ||
i: /^ *import(\s+([^\s,]+)\s*,?)?(\s*{(?:[^}]+)})?\s+from\s+['"].+['"]/gm, | ||
@@ -26,6 +27,8 @@ ias: /^ *import\s+(?:(.+?)\s*,\s*)?\*\s+as\s+.+?\s+from\s+['"].+['"]/gm, | ||
}) | ||
const s = SyncReplaceable(input, [makeCutRule(e), | ||
const s = SyncReplaceable(input, [ | ||
makeCutRule(ef), makeCutRule(e), | ||
makeCutRule(i), makeCutRule(ias), makeCutRule(ii)]) | ||
const tt = transpileJSX(s, config) | ||
const as = SyncReplaceable(tt, [makePasteRule(e), | ||
const as = SyncReplaceable(tt, [ | ||
makePasteRule(ef), makePasteRule(e), | ||
makePasteRule(i), makePasteRule(ias), makePasteRule(ii)]) | ||
@@ -32,0 +35,0 @@ return as |
## 24 January 2019 | ||
### 1.2.2 | ||
- [fix] Ignore `export from` statements. | ||
- [doc] Add [Tech Nation Visa](https://www.technation.sucks) footer. | ||
### 1.2.1 | ||
@@ -4,0 +9,0 @@ |
{ | ||
"name": "@a-la/jsx", | ||
"version": "1.2.1", | ||
"version": "1.2.2", | ||
"description": "The JSX Transform For ÀLaMode And Other Packages.", | ||
@@ -5,0 +5,0 @@ "main": "build", |
@@ -144,6 +144,21 @@ # @a-la/jsx | ||
(c) [À La Mode][1] 2019 | ||
<table> | ||
<tr> | ||
<th> | ||
<a href="https://artd.eco"> | ||
<img src="https://github.com/wrote/wrote/raw/master/images/artdeco.png" alt="Art Deco"> | ||
</a> | ||
</th> | ||
<th>© <a href="https://artd.eco">Art Deco</a> for <a href="https://alamode.cc">À La Mode</a> 2019</th> | ||
<th> | ||
<a href="https://www.technation.sucks" title="Tech Nation Visa"> | ||
<img src="https://github.com/wrote/wrote/raw/master/images/technation.gif" alt="Tech Nation Visa"> | ||
</a> | ||
</th> | ||
<th> | ||
<a href="https://www.technation.sucks">Tech Nation Visa Sucks</a> | ||
</th> | ||
</tr> | ||
</table> | ||
[1]: https://alamode.cc | ||
<p align="center"><a href="#table-of-contents"><img src=".documentary/section-breaks/-1.svg?sanitize=true"></a></p> |
@@ -12,4 +12,5 @@ import transpileJSX from './lib/components' | ||
const jsx = (input, config = {}) => { | ||
const { e, i, ias, ii } = makeMarkers({ | ||
const { e, ef, i, ias, ii } = makeMarkers({ | ||
e: /^ *export\s+(?:default\s+)?/mg, | ||
ef: /^ *export\s+{[^}]+}\s+from\s+(['"])(?:.+?)\1/mg, | ||
i: /^ *import(\s+([^\s,]+)\s*,?)?(\s*{(?:[^}]+)})?\s+from\s+['"].+['"]/gm, | ||
@@ -26,6 +27,8 @@ ias: /^ *import\s+(?:(.+?)\s*,\s*)?\*\s+as\s+.+?\s+from\s+['"].+['"]/gm, | ||
}) | ||
const s = SyncReplaceable(input, [makeCutRule(e), | ||
const s = SyncReplaceable(input, [ | ||
makeCutRule(ef), makeCutRule(e), | ||
makeCutRule(i), makeCutRule(ias), makeCutRule(ii)]) | ||
const tt = transpileJSX(s, config) | ||
const as = SyncReplaceable(tt, [makePasteRule(e), | ||
const as = SyncReplaceable(tt, [ | ||
makePasteRule(ef), makePasteRule(e), | ||
makePasteRule(i), makePasteRule(ias), makePasteRule(ii)]) | ||
@@ -32,0 +35,0 @@ return as |
40456
855
163