@b9g/crank 0.5.0-beta.5 → 0.5.0-beta.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,20 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var core = require('./core.cjs');
6
+
7
+ // This file is provided for compatibility reasons with the JSX automatic
8
+ function jsxAdapter(tag, props, key) {
9
+ // The new JSX transform extracts the key from props for reasons, but key is
10
+ // not a special property in Crank.
11
+ return core.createElement(tag, { ...props, key });
12
+ }
13
+ const Fragment = "";
14
+ const jsx = jsxAdapter;
15
+ const jsxs = jsxAdapter;
16
+
17
+ exports.Fragment = Fragment;
18
+ exports.jsx = jsx;
19
+ exports.jsxs = jsxs;
20
+ //# sourceMappingURL=jsx-runtime.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jsx-runtime.cjs","sources":["../src/jsx-runtime.ts"],"sourcesContent":["// This file is provided for compatibility reasons with the JSX automatic\n// runtime. Besides automatic imports, the JSX automatic runtime provides no\n// actual advantage over the createElement transform.\nimport {createElement} from \"./core.js\";\n\nfunction jsxAdapter(tag: any, props: Record<string, any>, key: any) {\n\t// The new JSX transform extracts the key from props for reasons, but key is\n\t// not a special property in Crank.\n\treturn createElement(tag, {...props, key});\n}\n\nexport const Fragment = \"\";\nexport const jsx = jsxAdapter;\nexport const jsxs = jsxAdapter;\n"],"names":["createElement"],"mappings":";;;;;;AAAA;AAKA,SAAS,UAAU,CAAC,GAAQ,EAAE,KAA0B,EAAE,GAAQ,EAAA;;;IAGjE,OAAOA,kBAAa,CAAC,GAAG,EAAE,EAAC,GAAG,KAAK,EAAE,GAAG,EAAC,CAAC,CAAC;AAC5C,CAAC;AAEM,MAAM,QAAQ,GAAG,GAAG;AACpB,MAAM,GAAG,GAAG,WAAW;AACvB,MAAM,IAAI,GAAG;;;;;;"}
@@ -0,0 +1,5 @@
1
+ declare function jsxAdapter(tag: any, props: Record<string, any>, key: any): import("./core.js").Element<any>;
2
+ export declare const Fragment = "";
3
+ export declare const jsx: typeof jsxAdapter;
4
+ export declare const jsxs: typeof jsxAdapter;
5
+ export {};
package/jsx-runtime.js ADDED
@@ -0,0 +1,15 @@
1
+ /// <reference types="jsx-runtime.d.ts" />
2
+ import { createElement } from './core.js';
3
+
4
+ // This file is provided for compatibility reasons with the JSX automatic
5
+ function jsxAdapter(tag, props, key) {
6
+ // The new JSX transform extracts the key from props for reasons, but key is
7
+ // not a special property in Crank.
8
+ return createElement(tag, { ...props, key });
9
+ }
10
+ const Fragment = "";
11
+ const jsx = jsxAdapter;
12
+ const jsxs = jsxAdapter;
13
+
14
+ export { Fragment, jsx, jsxs };
15
+ //# sourceMappingURL=jsx-runtime.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jsx-runtime.js","sources":["../src/jsx-runtime.ts"],"sourcesContent":["// This file is provided for compatibility reasons with the JSX automatic\n// runtime. Besides automatic imports, the JSX automatic runtime provides no\n// actual advantage over the createElement transform.\nimport {createElement} from \"./core.js\";\n\nfunction jsxAdapter(tag: any, props: Record<string, any>, key: any) {\n\t// The new JSX transform extracts the key from props for reasons, but key is\n\t// not a special property in Crank.\n\treturn createElement(tag, {...props, key});\n}\n\nexport const Fragment = \"\";\nexport const jsx = jsxAdapter;\nexport const jsxs = jsxAdapter;\n"],"names":[],"mappings":";;;AAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAKA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,UAAU,CAAC,CAAA,CAAA,CAAQ,EAAE,CAA0B,CAAA,CAAA,CAAA,CAAA,CAAA,CAAE,GAAQ,CAAA,CAAA,CAAA,CAAA;;;IAGjE,CAAO,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAa,CAAC,CAAA,CAAA,CAAG,CAAE,CAAA,CAAA,CAAC,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAK,CAAE,CAAA,CAAA,CAAA,CAAG,CAAC,CAAA,CAAC,CAAC,CAAA;AAC5C,CAAC,CAAA;AAEM,CAAM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAQ,GAAG,CAAG,CAAA,CAAA,CAAA;AACpB,CAAM,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAG,GAAG,CAAW,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AACvB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAM,IAAI,CAAG,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@b9g/crank",
3
- "version": "0.5.0-beta.5",
3
+ "version": "0.5.0-beta.6",
4
4
  "description": "Write JSX-driven components with functions, promises and generators.",
5
5
  "homepage": "https://crank.js.org",
6
6
  "bugs": {
@@ -49,6 +49,14 @@
49
49
  "import": "./core.js",
50
50
  "require": "./core.cjs"
51
51
  },
52
+ "./jsx-runtime": {
53
+ "import": "./jsx-runtime.js",
54
+ "require": "./jsx-runtime.cjs"
55
+ },
56
+ "./jsx-runtime.js": {
57
+ "import": "./jsx-runtime.js",
58
+ "require": "./jsx-runtime.cjs"
59
+ },
52
60
  "./package.json": "./package.json",
53
61
  "./tags": {
54
62
  "import": "./tags.js",