editor-input
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

Integration React & Angular

Vscode autocompletion

add .vscode/settings.json file

{
    "html.customData": ["@node_modules/editor-input/html.customData.json"]
}

React

main file

import { defineCustomElements, JSX as LocalJSX, applyPolyfills } from 'editor-input/loader';
import { HTMLAttributes } from 'react';

type StencilToReact = {
    [P in keyof LocalJSX.IntrinsicElements]?: LocalJSX.IntrinsicElements[P] & Omit<HTMLAttributes<Element>, 'className'> & { class?: string };
};

declare global {
    export namespace JSX {
        interface IntrinsicElements extends StencilToReact {}
    }
}

applyPolyfills().then(() => defineCustomElements(window));

Anguler

https://stenciljs.com/docs/angular

main.ts

import { defineCustomElements, applyPolyfills } from 'editor-input/loader';

applyPolyfills().then(() => {
    defineCustomElements();
});

using

<editor-input></<editor-input>>

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
1.0.11latest

Version History

VersionDownloads (Last 7 Days)Published
1.0.11
1.0.00

Package Sidebar

Install

npm i editor-input

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

245 kB

Total Files

40

Last publish

Collaborators

  • barnuri