@teambit/compilation.aspect-docs.compiler 0.0.0-14af66dc3b869c50300c7b2881c320aaf823d1eb
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.
- package/compiler.composition.tsx +12 -0
- package/compiler.docs.mdx +34 -0
- package/compiler.mdx +63 -0
- package/dist/compiler.composition.d.ts +2 -0
- package/dist/compiler.composition.js +15 -0
- package/dist/compiler.composition.js.map +1 -0
- package/dist/compiler.docs.mdx +34 -0
- package/dist/compiler.mdx.js +59 -0
- package/dist/compiler.mdx.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -0
- package/dist/preview-1763415264420.js +7 -0
- package/index.ts +1 -0
- package/package.json +52 -0
- package/types/asset.d.ts +29 -0
- package/types/style.d.ts +42 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ThemeCompositions } from '@teambit/documenter.theme.theme-compositions';
|
|
3
|
+
import { MDXLayout } from '@teambit/mdx.ui.mdx-layout';
|
|
4
|
+
import { Compiler } from './index';
|
|
5
|
+
|
|
6
|
+
export const CompilerDocs = () => (
|
|
7
|
+
<ThemeCompositions>
|
|
8
|
+
<MDXLayout>
|
|
9
|
+
<Compiler />
|
|
10
|
+
</MDXLayout>
|
|
11
|
+
</ThemeCompositions>
|
|
12
|
+
);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: 'Docs for Compiler aspect'
|
|
3
|
+
labels: ['docs', 'aspect', 'extensions']
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
import { Compiler } from './index';
|
|
7
|
+
|
|
8
|
+
## Static Content Page in MDX
|
|
9
|
+
|
|
10
|
+
Docs for Compiler aspect
|
|
11
|
+
|
|
12
|
+
### Component usage
|
|
13
|
+
|
|
14
|
+
Use your component in any mdx file:
|
|
15
|
+
|
|
16
|
+
```js
|
|
17
|
+
import { Compiler } from '@teambit/aspect-docs.compiler';
|
|
18
|
+
|
|
19
|
+
<Compiler />;
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
### Render with theme and MDX providers
|
|
23
|
+
|
|
24
|
+
```js
|
|
25
|
+
import { ThemeCompositions } from '@teambit/documenter.theme.theme-compositions';
|
|
26
|
+
import { MDXLayout } from '@teambit/ui.mdx-layout';
|
|
27
|
+
import { Compiler } from '@teambit/aspect-docs.compiler';
|
|
28
|
+
|
|
29
|
+
<ThemeCompositions>
|
|
30
|
+
<MDXLayout>
|
|
31
|
+
<Compiler />
|
|
32
|
+
</MDXLayout>
|
|
33
|
+
</ThemeCompositions>;
|
|
34
|
+
```
|
package/compiler.mdx
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
## Workspace Configuration
|
|
2
|
+
|
|
3
|
+
The compiler is configured inside an environment and not directly on the component level.
|
|
4
|
+
|
|
5
|
+
### As a task
|
|
6
|
+
|
|
7
|
+
A task is running with `bit build` or during the tag process on the capsules or the workspace (depends on the specific compiler implementation).
|
|
8
|
+
|
|
9
|
+
The env extension should have this compiler extension as a dependency first, then add to the `getBuildPipe()` array the following: `this.compiler.createTask()`.
|
|
10
|
+
|
|
11
|
+
### As a command
|
|
12
|
+
|
|
13
|
+
A command is running on the workspace.
|
|
14
|
+
|
|
15
|
+
To run: `bit compile`.
|
|
16
|
+
|
|
17
|
+
An example of configuring a compiler in the React env.
|
|
18
|
+
|
|
19
|
+
```jsx
|
|
20
|
+
/**
|
|
21
|
+
* returns a component compiler.
|
|
22
|
+
*/
|
|
23
|
+
getCompiler(): Compiler {
|
|
24
|
+
// eslint-disable-next-line global-require
|
|
25
|
+
const tsConfig = require('./typescript/tsconfig.json');
|
|
26
|
+
return this.ts.createCompiler(tsConfig);
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Compiler Implementation
|
|
31
|
+
|
|
32
|
+
The compiler is responsible for two processes:
|
|
33
|
+
|
|
34
|
+
### compile during development
|
|
35
|
+
|
|
36
|
+
This compilation takes place on the workspace and the dists are saved inside the component dir.
|
|
37
|
+
The provider should implement `transpileFile` function as follows:
|
|
38
|
+
|
|
39
|
+
```jsx
|
|
40
|
+
transpileFile: (fileContent: string, options: { componentDir: string, filePath: string }) => Array<{ outputText: string, outputPath: string }> | null;
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
In case the compiler receives an unsupported file, it should return null.
|
|
44
|
+
|
|
45
|
+
### compile for build (during the tag command)
|
|
46
|
+
|
|
47
|
+
This compilation takes place on the isolated capsule.
|
|
48
|
+
The provider should implement `build` function which returns the exit-code and the dist dir.
|
|
49
|
+
From Compiler interface:
|
|
50
|
+
|
|
51
|
+
```jsx
|
|
52
|
+
build(context: BuildContext): Promise<BuildResults>;
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Points to consider when writing a compiler
|
|
56
|
+
|
|
57
|
+
### Debugging experience on the workspace
|
|
58
|
+
|
|
59
|
+
Since the dists are written into the node_modules/component-name/dist-dir, the debugger needs to know where to find the source files. This can be easily achieved by setting the `sourceRoot` of the source-map file to the component-dir. As a reminder, this directory is passed to the `transpile()` method.
|
|
60
|
+
|
|
61
|
+
### Error handling during build process
|
|
62
|
+
|
|
63
|
+
Without proper error handling, the `build()` will exit an the first error found. Catch the errors and add them to the `ComponentResult.errors[]` you return per component.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.CompilerDocs = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const documenter_theme_theme_compositions_1 = require("@teambit/documenter.theme.theme-compositions");
|
|
9
|
+
const mdx_ui_mdx_layout_1 = require("@teambit/mdx.ui.mdx-layout");
|
|
10
|
+
const index_1 = require("./index");
|
|
11
|
+
const CompilerDocs = () => (react_1.default.createElement(documenter_theme_theme_compositions_1.ThemeCompositions, null,
|
|
12
|
+
react_1.default.createElement(mdx_ui_mdx_layout_1.MDXLayout, null,
|
|
13
|
+
react_1.default.createElement(index_1.Compiler, null))));
|
|
14
|
+
exports.CompilerDocs = CompilerDocs;
|
|
15
|
+
//# sourceMappingURL=compiler.composition.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compiler.composition.js","sourceRoot":"","sources":["../compiler.composition.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAC1B,sGAAiF;AACjF,kEAAuD;AACvD,mCAAmC;AAE5B,MAAM,YAAY,GAAG,GAAG,EAAE,CAAC,CAChC,8BAAC,uDAAiB;IAChB,8BAAC,6BAAS;QACR,8BAAC,gBAAQ,OAAG,CACF,CACM,CACrB,CAAC;AANW,QAAA,YAAY,gBAMvB"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: 'Docs for Compiler aspect'
|
|
3
|
+
labels: ['docs', 'aspect', 'extensions']
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
import { Compiler } from './index';
|
|
7
|
+
|
|
8
|
+
## Static Content Page in MDX
|
|
9
|
+
|
|
10
|
+
Docs for Compiler aspect
|
|
11
|
+
|
|
12
|
+
### Component usage
|
|
13
|
+
|
|
14
|
+
Use your component in any mdx file:
|
|
15
|
+
|
|
16
|
+
```js
|
|
17
|
+
import { Compiler } from '@teambit/aspect-docs.compiler';
|
|
18
|
+
|
|
19
|
+
<Compiler />;
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
### Render with theme and MDX providers
|
|
23
|
+
|
|
24
|
+
```js
|
|
25
|
+
import { ThemeCompositions } from '@teambit/documenter.theme.theme-compositions';
|
|
26
|
+
import { MDXLayout } from '@teambit/ui.mdx-layout';
|
|
27
|
+
import { Compiler } from '@teambit/aspect-docs.compiler';
|
|
28
|
+
|
|
29
|
+
<ThemeCompositions>
|
|
30
|
+
<MDXLayout>
|
|
31
|
+
<Compiler />
|
|
32
|
+
</MDXLayout>
|
|
33
|
+
</ThemeCompositions>;
|
|
34
|
+
```
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = MDXContent;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _react2 = require("@mdx-js/react");
|
|
9
|
+
var _excluded = ["components"]; // @ts-nocheck
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
11
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
12
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
13
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
14
|
+
/* @jsxRuntime classic */
|
|
15
|
+
/* @jsx mdx */
|
|
16
|
+
|
|
17
|
+
var layoutProps = {};
|
|
18
|
+
var MDXLayout = "wrapper";
|
|
19
|
+
function MDXContent(_ref) {
|
|
20
|
+
var components = _ref.components,
|
|
21
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
22
|
+
return (0, _react2.mdx)(MDXLayout, _extends({}, layoutProps, props, {
|
|
23
|
+
components: components,
|
|
24
|
+
mdxType: "MDXLayout"
|
|
25
|
+
}), (0, _react2.mdx)("h2", null, "Workspace Configuration"), (0, _react2.mdx)("p", null, "The compiler is configured inside an environment and not directly on the component level."), (0, _react2.mdx)("h3", null, "As a task"), (0, _react2.mdx)("p", null, "A task is running with ", (0, _react2.mdx)("inlineCode", {
|
|
26
|
+
parentName: "p"
|
|
27
|
+
}, "bit build"), " or during the tag process on the capsules or the workspace (depends on the specific compiler implementation)."), (0, _react2.mdx)("p", null, "The env extension should have this compiler extension as a dependency first, then add to the ", (0, _react2.mdx)("inlineCode", {
|
|
28
|
+
parentName: "p"
|
|
29
|
+
}, "getBuildPipe()"), " array the following: ", (0, _react2.mdx)("inlineCode", {
|
|
30
|
+
parentName: "p"
|
|
31
|
+
}, "this.compiler.createTask()"), "."), (0, _react2.mdx)("h3", null, "As a command"), (0, _react2.mdx)("p", null, "A command is running on the workspace."), (0, _react2.mdx)("p", null, "To run: ", (0, _react2.mdx)("inlineCode", {
|
|
32
|
+
parentName: "p"
|
|
33
|
+
}, "bit compile"), "."), (0, _react2.mdx)("p", null, "An example of configuring a compiler in the React env."), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
|
|
34
|
+
parentName: "pre",
|
|
35
|
+
"className": "language-jsx"
|
|
36
|
+
}, "/**\n * returns a component compiler.\n */\ngetCompiler(): Compiler {\n // eslint-disable-next-line global-require\n const tsConfig = require('./typescript/tsconfig.json');\n return this.ts.createCompiler(tsConfig);\n}\n")), (0, _react2.mdx)("h2", null, "Compiler Implementation"), (0, _react2.mdx)("p", null, "The compiler is responsible for two processes:"), (0, _react2.mdx)("h3", null, "compile during development"), (0, _react2.mdx)("p", null, "This compilation takes place on the workspace and the dists are saved inside the component dir.\nThe provider should implement ", (0, _react2.mdx)("inlineCode", {
|
|
37
|
+
parentName: "p"
|
|
38
|
+
}, "transpileFile"), " function as follows:"), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
|
|
39
|
+
parentName: "pre",
|
|
40
|
+
"className": "language-jsx"
|
|
41
|
+
}, "transpileFile: (fileContent: string, options: { componentDir: string, filePath: string }) => Array<{ outputText: string, outputPath: string }> | null;\n")), (0, _react2.mdx)("p", null, "In case the compiler receives an unsupported file, it should return null."), (0, _react2.mdx)("h3", null, "compile for build (during the tag command)"), (0, _react2.mdx)("p", null, "This compilation takes place on the isolated capsule.\nThe provider should implement ", (0, _react2.mdx)("inlineCode", {
|
|
42
|
+
parentName: "p"
|
|
43
|
+
}, "build"), " function which returns the exit-code and the dist dir.\nFrom Compiler interface:"), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
|
|
44
|
+
parentName: "pre",
|
|
45
|
+
"className": "language-jsx"
|
|
46
|
+
}, "build(context: BuildContext): Promise<BuildResults>;\n")), (0, _react2.mdx)("h2", null, "Points to consider when writing a compiler"), (0, _react2.mdx)("h3", null, "Debugging experience on the workspace"), (0, _react2.mdx)("p", null, "Since the dists are written into the node_modules/component-name/dist-dir, the debugger needs to know where to find the source files. This can be easily achieved by setting the ", (0, _react2.mdx)("inlineCode", {
|
|
47
|
+
parentName: "p"
|
|
48
|
+
}, "sourceRoot"), " of the source-map file to the component-dir. As a reminder, this directory is passed to the ", (0, _react2.mdx)("inlineCode", {
|
|
49
|
+
parentName: "p"
|
|
50
|
+
}, "transpile()"), " method."), (0, _react2.mdx)("h3", null, "Error handling during build process"), (0, _react2.mdx)("p", null, "Without proper error handling, the ", (0, _react2.mdx)("inlineCode", {
|
|
51
|
+
parentName: "p"
|
|
52
|
+
}, "build()"), " will exit an the first error found. Catch the errors and add them to the ", (0, _react2.mdx)("inlineCode", {
|
|
53
|
+
parentName: "p"
|
|
54
|
+
}, "ComponentResult.errors[]"), " you return per component."));
|
|
55
|
+
}
|
|
56
|
+
;
|
|
57
|
+
MDXContent.isMDXComponent = true;
|
|
58
|
+
|
|
59
|
+
//# sourceMappingURL=compiler.mdx.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_react2","_excluded","e","__esModule","_extends","Object","assign","bind","n","arguments","length","t","r","hasOwnProperty","call","apply","_objectWithoutProperties","o","i","_objectWithoutPropertiesLoose","getOwnPropertySymbols","indexOf","propertyIsEnumerable","layoutProps","MDXLayout","MDXContent","_ref","components","props","mdx","mdxType","parentName","isMDXComponent"],"sourceRoot":"/home/circleci/Library/Caches/Bit/capsules/8891be5ad/teambit.compilation_aspect-docs_compiler@14af66dc3b869c50300c7b2881c320aaf823d1eb","sources":["compiler.mdx.js"],"sourcesContent":["\n// @ts-nocheck\nimport React from 'react'\nimport { mdx } from '@mdx-js/react'\n\n/* @jsxRuntime classic */\n/* @jsx mdx */\n\n\n\n\nconst layoutProps = {\n \n};\nconst MDXLayout = \"wrapper\"\nexport default function MDXContent({\n components,\n ...props\n}) {\n return <MDXLayout {...layoutProps} {...props} components={components} mdxType=\"MDXLayout\">\n <h2>{`Workspace Configuration`}</h2>\n <p>{`The compiler is configured inside an environment and not directly on the component level.`}</p>\n <h3>{`As a task`}</h3>\n <p>{`A task is running with `}<inlineCode parentName=\"p\">{`bit build`}</inlineCode>{` or during the tag process on the capsules or the workspace (depends on the specific compiler implementation).`}</p>\n <p>{`The env extension should have this compiler extension as a dependency first, then add to the `}<inlineCode parentName=\"p\">{`getBuildPipe()`}</inlineCode>{` array the following: `}<inlineCode parentName=\"p\">{`this.compiler.createTask()`}</inlineCode>{`.`}</p>\n <h3>{`As a command`}</h3>\n <p>{`A command is running on the workspace.`}</p>\n <p>{`To run: `}<inlineCode parentName=\"p\">{`bit compile`}</inlineCode>{`.`}</p>\n <p>{`An example of configuring a compiler in the React env.`}</p>\n <pre><code parentName=\"pre\" {...{\n \"className\": \"language-jsx\"\n }}>{`/**\n * returns a component compiler.\n */\ngetCompiler(): Compiler {\n // eslint-disable-next-line global-require\n const tsConfig = require('./typescript/tsconfig.json');\n return this.ts.createCompiler(tsConfig);\n}\n`}</code></pre>\n <h2>{`Compiler Implementation`}</h2>\n <p>{`The compiler is responsible for two processes:`}</p>\n <h3>{`compile during development`}</h3>\n <p>{`This compilation takes place on the workspace and the dists are saved inside the component dir.\nThe provider should implement `}<inlineCode parentName=\"p\">{`transpileFile`}</inlineCode>{` function as follows:`}</p>\n <pre><code parentName=\"pre\" {...{\n \"className\": \"language-jsx\"\n }}>{`transpileFile: (fileContent: string, options: { componentDir: string, filePath: string }) => Array<{ outputText: string, outputPath: string }> | null;\n`}</code></pre>\n <p>{`In case the compiler receives an unsupported file, it should return null.`}</p>\n <h3>{`compile for build (during the tag command)`}</h3>\n <p>{`This compilation takes place on the isolated capsule.\nThe provider should implement `}<inlineCode parentName=\"p\">{`build`}</inlineCode>{` function which returns the exit-code and the dist dir.\nFrom Compiler interface:`}</p>\n <pre><code parentName=\"pre\" {...{\n \"className\": \"language-jsx\"\n }}>{`build(context: BuildContext): Promise<BuildResults>;\n`}</code></pre>\n <h2>{`Points to consider when writing a compiler`}</h2>\n <h3>{`Debugging experience on the workspace`}</h3>\n <p>{`Since the dists are written into the node_modules/component-name/dist-dir, the debugger needs to know where to find the source files. This can be easily achieved by setting the `}<inlineCode parentName=\"p\">{`sourceRoot`}</inlineCode>{` of the source-map file to the component-dir. As a reminder, this directory is passed to the `}<inlineCode parentName=\"p\">{`transpile()`}</inlineCode>{` method.`}</p>\n <h3>{`Error handling during build process`}</h3>\n <p>{`Without proper error handling, the `}<inlineCode parentName=\"p\">{`build()`}</inlineCode>{` will exit an the first error found. Catch the errors and add them to the `}<inlineCode parentName=\"p\">{`ComponentResult.errors[]`}</inlineCode>{` you return per component.`}</p>\n </MDXLayout>;\n}\n;\nMDXContent.isMDXComponent = true;"],"mappings":";;;;;;AAEA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AAAmC,IAAAE,SAAA,mBAFnC;AAAA,SAAAH,uBAAAI,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,gBAAAA,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,EAAC;EAAG,6BAAyC,CAAC,8BAAiC,CACrQ,CAAC;AAChB;AACA;AACAN,UAAU,CAACO,cAAc,GAAG,IAAI","ignoreList":[]}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Compiler } from './compiler.mdx';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.Compiler = void 0;
|
|
7
|
+
var compiler_mdx_1 = require("./compiler.mdx");
|
|
8
|
+
Object.defineProperty(exports, "Compiler", { enumerable: true, get: function () { return __importDefault(compiler_mdx_1).default; } });
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;;;;AAAA,+CAAqD;AAA5C,yHAAA,OAAO,OAAY"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad/teambit.compilation_aspect-docs_compiler@14af66dc3b869c50300c7b2881c320aaf823d1eb/dist/compiler.composition.js';
|
|
2
|
+
import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad/teambit.compilation_aspect-docs_compiler@14af66dc3b869c50300c7b2881c320aaf823d1eb/dist/compiler.docs.mdx';
|
|
3
|
+
|
|
4
|
+
export const compositions = [compositions_0];
|
|
5
|
+
export const overview = [overview_0];
|
|
6
|
+
|
|
7
|
+
export const compositions_metadata = {"compositions":[{"displayName":"Compiler docs","identifier":"CompilerDocs"}]};
|
package/index.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Compiler } from './compiler.mdx';
|
package/package.json
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@teambit/compilation.aspect-docs.compiler",
|
|
3
|
+
"version": "0.0.0-14af66dc3b869c50300c7b2881c320aaf823d1eb",
|
|
4
|
+
"homepage": "https://bit.cloud/teambit/compilation/aspect-docs/compiler",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"componentId": {
|
|
7
|
+
"scope": "teambit.compilation",
|
|
8
|
+
"name": "aspect-docs/compiler",
|
|
9
|
+
"version": "14af66dc3b869c50300c7b2881c320aaf823d1eb"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"core-js": "^3.0.0",
|
|
13
|
+
"@mdx-js/react": "1.6.22",
|
|
14
|
+
"@teambit/mdx.ui.mdx-scope-context": "1.0.0"
|
|
15
|
+
},
|
|
16
|
+
"devDependencies": {
|
|
17
|
+
"@types/react": "^17.0.8",
|
|
18
|
+
"@types/mocha": "9.1.0",
|
|
19
|
+
"@types/node": "12.20.4",
|
|
20
|
+
"@types/react-dom": "^17.0.5",
|
|
21
|
+
"@types/jest": "^26.0.0",
|
|
22
|
+
"@babel/runtime": "7.20.0",
|
|
23
|
+
"@types/testing-library__jest-dom": "5.9.5",
|
|
24
|
+
"@teambit/documenter.theme.theme-compositions": "4.1.5",
|
|
25
|
+
"@teambit/mdx.ui.mdx-layout": "1.0.12"
|
|
26
|
+
},
|
|
27
|
+
"peerDependencies": {
|
|
28
|
+
"react": "^16.8.0 || ^17.0.0",
|
|
29
|
+
"react-dom": "^16.8.0 || ^17.0.0"
|
|
30
|
+
},
|
|
31
|
+
"license": "Apache-2.0",
|
|
32
|
+
"optionalDependencies": {},
|
|
33
|
+
"peerDependenciesMeta": {},
|
|
34
|
+
"private": false,
|
|
35
|
+
"engines": {
|
|
36
|
+
"node": ">=12.22.0"
|
|
37
|
+
},
|
|
38
|
+
"repository": {
|
|
39
|
+
"type": "git",
|
|
40
|
+
"url": "https://github.com/teambit/bit"
|
|
41
|
+
},
|
|
42
|
+
"keywords": [
|
|
43
|
+
"bit",
|
|
44
|
+
"components",
|
|
45
|
+
"collaboration",
|
|
46
|
+
"web",
|
|
47
|
+
"react",
|
|
48
|
+
"react-components",
|
|
49
|
+
"angular",
|
|
50
|
+
"angular-components"
|
|
51
|
+
]
|
|
52
|
+
}
|
package/types/asset.d.ts
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
declare module '*.png' {
|
|
2
|
+
const value: any;
|
|
3
|
+
export = value;
|
|
4
|
+
}
|
|
5
|
+
declare module '*.svg' {
|
|
6
|
+
import type { FunctionComponent, SVGProps } from 'react';
|
|
7
|
+
|
|
8
|
+
export const ReactComponent: FunctionComponent<SVGProps<SVGSVGElement> & { title?: string }>;
|
|
9
|
+
const src: string;
|
|
10
|
+
export default src;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// @TODO Gilad
|
|
14
|
+
declare module '*.jpg' {
|
|
15
|
+
const value: any;
|
|
16
|
+
export = value;
|
|
17
|
+
}
|
|
18
|
+
declare module '*.jpeg' {
|
|
19
|
+
const value: any;
|
|
20
|
+
export = value;
|
|
21
|
+
}
|
|
22
|
+
declare module '*.gif' {
|
|
23
|
+
const value: any;
|
|
24
|
+
export = value;
|
|
25
|
+
}
|
|
26
|
+
declare module '*.bmp' {
|
|
27
|
+
const value: any;
|
|
28
|
+
export = value;
|
|
29
|
+
}
|
package/types/style.d.ts
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
declare module '*.module.css' {
|
|
2
|
+
const classes: { readonly [key: string]: string };
|
|
3
|
+
export default classes;
|
|
4
|
+
}
|
|
5
|
+
declare module '*.module.scss' {
|
|
6
|
+
const classes: { readonly [key: string]: string };
|
|
7
|
+
export default classes;
|
|
8
|
+
}
|
|
9
|
+
declare module '*.module.sass' {
|
|
10
|
+
const classes: { readonly [key: string]: string };
|
|
11
|
+
export default classes;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
declare module '*.module.less' {
|
|
15
|
+
const classes: { readonly [key: string]: string };
|
|
16
|
+
export default classes;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
declare module '*.less' {
|
|
20
|
+
const classes: { readonly [key: string]: string };
|
|
21
|
+
export default classes;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
declare module '*.css' {
|
|
25
|
+
const classes: { readonly [key: string]: string };
|
|
26
|
+
export default classes;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
declare module '*.sass' {
|
|
30
|
+
const classes: { readonly [key: string]: string };
|
|
31
|
+
export default classes;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
declare module '*.scss' {
|
|
35
|
+
const classes: { readonly [key: string]: string };
|
|
36
|
+
export default classes;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
declare module '*.mdx' {
|
|
40
|
+
const component: any;
|
|
41
|
+
export default component;
|
|
42
|
+
}
|