Skip to content
Snippets Groups Projects
Commit 700eb847 authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

Make sure every package supports eslint and run in CI

parent 5444da37
No related branches found
No related tags found
1 merge request!45Make sure every package supports eslint and run in CI
Pipeline #25281 passed
Showing
with 51 additions and 33 deletions
......@@ -28,6 +28,9 @@ linting:
script:
- yarn install
- yarn run lint
- cd toolkit-showcase
- yarn install
- yarn run lint
publish:
stage: deploy
......
/vendor/**
/dist/**
/*.js
\ No newline at end of file
{
"root": true,
"env": {
"browser": true,
"es6": true,
"mocha": true
},
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint"
],
"extends": [
"eslint:recommended"
]
}
\ No newline at end of file
......@@ -17,6 +17,8 @@
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-node-resolve": "^11.0.0",
"@types/mocha": "^8.2.0",
"@typescript-eslint/eslint-plugin": "^4.22.0",
"@typescript-eslint/parser": "^4.22.0",
"chai": "^4.2.0",
"karma": "^6.0.0",
"karma-chrome-launcher": "^3.0.0",
......@@ -42,6 +44,7 @@
"clean": "rm dist/*",
"build": "rollup -c",
"watch": "rollup -c --watch",
"test": "rollup -c --environment BUILD:test && karma start --singleRun"
"test": "rollup -c --environment BUILD:test && karma start --singleRun",
"lint": "eslint . --ext .js,.ts"
}
}
import {html, LitElement} from 'lit-element';
import {html, LitElement, TemplateResult} from 'lit-element';
import {TypeScriptExample} from './typescript-example';
import * as commonUtils from '@dbp-toolkit/common/utils';
import { ScopedElementsMixin } from '@open-wc/scoped-elements';
import { ScopedElementsMixin, ScopedElementsMap } from '@open-wc/scoped-elements';
export class TypeScriptExampleDemo extends ScopedElementsMixin(LitElement) {
static get scopedElements() {
static get scopedElements(): ScopedElementsMap {
return {
'dbp-typescript-example': TypeScriptExample,
};
}
render() {
render(): TemplateResult {
return html`
<dbp-typescript-example lang="de"></dbp-typescript-example>
`;
......
......@@ -3,7 +3,7 @@ import {i18n} from './i18n';
export class TypeScriptExample extends LitElement {
private _i18n: any;
private _i18n;
constructor() {
super();
......
/vendor/**
/dist/**
/*.js
\ No newline at end of file
{
"root": true,
"extends": "./../eslint.common.json"
}
\ No newline at end of file
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {DbpAuthDemo} from '@dbp-toolkit/auth/src/dbp-auth-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/auth/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {CheckInPlaceSelectDemo} from '@dbp-toolkit/check-in-place-select/src/dbp-check-in-place-select-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/check-in-place-select/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {DbpCommonDemo} from '@dbp-toolkit/common/dbp-common-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/common/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {DataTableViewDemo} from '@dbp-toolkit/data-table-view/src/dbp-data-table-view-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/data-table-view/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
//import {ClassName} from '@dbp-toolkit/package-name/src/dbp-demo-activity-name'; TODO
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
// import readme from '@dbp-toolkit/class-name/README.md'; TODO
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
class DbpActivityNameDemoActivity extends ScopedElementsMixin(AdapterLitElement) { //TODO
export class DbpActivityNameDemoActivity extends ScopedElementsMixin(AdapterLitElement) { //TODO
constructor() {
super();
this.lang = 'en';
......@@ -61,7 +59,7 @@ class DbpActivityNameDemoActivity extends ScopedElementsMixin(AdapterLitElement)
return html`
<!--
TODO
${unsafeHTML(readme)}
${unsafeHTML('readme')}
<dbp-class-name-demo id="demo" lang="${this.lang}" entry-point-url="${this.entryPointUrl}"></dbp-class-name-demo>
-->
`;
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {FileSourceDemo} from '@dbp-toolkit/file-handling/src/demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/file-handling/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {KnowledgeBaseWebPageElementViewDemo} from '@dbp-toolkit/knowledge-base-web-page-element-view/src/dbp-knowledge-base-web-page-element-view-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/knowledge-base-web-page-element-view/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {LanguageSelectDemo} from '@dbp-toolkit/language-select/src/dbp-language-select-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/language-select/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {MatomoDemo} from '@dbp-toolkit/matomo/src/dbp-matomo-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/matomo/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {NotificationDemo} from '@dbp-toolkit/notification/src/dbp-notification-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/notification/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {OrganizationSelectDemo} from '@dbp-toolkit/organization-select/src/dbp-organization-select-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/organization-select/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
import {css, html, LitElement} from 'lit-element';
import {css, html} from 'lit-element';
import {ScopedElementsMixin} from '@open-wc/scoped-elements';
import {PersonProfileDemo} from '@dbp-toolkit/person-profile/src/dbp-person-profile-demo';
import * as commonUtils from '@dbp-toolkit/common/utils';
import * as commonStyles from '@dbp-toolkit/common/styles';
import {unsafeHTML} from 'lit-html/directives/unsafe-html.js';
import readme from '@dbp-toolkit/person-profile/README.md';
import highlightCSSPath from 'highlight.js/styles/default.css';
import * as demoStyles from "./styles";
import {AdapterLitElement} from "@dbp-toolkit/provider/src/adapter-lit-element";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment