Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

always run the linters in CI #287

Merged
merged 1 commit into from
Sep 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ jobs:
with:
node-version: 20.x
- run: npm i
- run: npm run lint
- run: npm run build --if-present
- run: npm test

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@
"dev": "webpack-cli serve --mode=development --env development --open",
"prod": "webpack-cli serve --mode=production --env production --open",
"doc:publish": "node scripts/publish-ghpages.js",
"lint": "eslint './{examples,src}/**/*.{ts,tsx}'",
"lint:fix": "eslint './{examples,src}/**/*.{ts,tsx}' --fix",
"lint": "eslint './{examples,src,test}/**/*.{ts,tsx}'",
"lint:fix": "eslint './{examples,src,test}/**/*.{ts,tsx}' --fix",
"test": "jest",
"codecov": "curl -s https://codecov.io/bash | bash",
"prepare": "npm run build:lib",
Expand Down
2 changes: 1 addition & 1 deletion src/layer/ROSM.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {default as LayerRaster, RLayerRasterProps} from './RLayerRaster';
/**
* @propsfor ROSM
*/
// eslint-disable-next-line @typescript-eslint/no-empty-interface
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
export interface ROSMProps extends RLayerRasterProps {}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/layer/ROSMWebGL.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {default as RLayerWebGL, RLayerWebGLProps} from './RLayerWebGL';
/**
* @propsfor ROSMWebGL
*/
// eslint-disable-next-line @typescript-eslint/no-empty-interface
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
export interface ROSMWebGLProps extends RLayerWebGLProps {}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/style/RBackground.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import debug from '../debug';
/**
* @propsfor RBackground
*/
// eslint-disable-next-line @typescript-eslint/no-empty-interface
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
export interface RBackgroundProps extends RBaseStyleProps {}

type Background = {
Expand Down
2 changes: 1 addition & 1 deletion src/style/RBaseStyle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import debug from '../debug';
/**
* @propsfor RBaseStyle
*/
// eslint-disable-next-line @typescript-eslint/no-empty-interface
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
export interface RBaseStyleProps extends PropsWithChildren<unknown> {}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/style/RStyleArray.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export default class RStyleArray extends RStyle {
if (this.props.render) {
const element = this.props.render(f, r);
React.Children.map(element.props.children, (child) => {
// eslint-disable-next-line @typescript-eslint/ban-types
// eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
if (React.isValidElement(child) && (child.type as Function) !== RStyle)
throw new TypeError('An RStyleArray should contain only RStyle elements');
});
Expand All @@ -55,7 +55,7 @@ export default class RStyleArray extends RStyle {

render(): JSX.Element {
React.Children.map(this.props.children, (child) => {
// eslint-disable-next-line @typescript-eslint/ban-types
// eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
if (React.isValidElement(child) && (child.type as Function) !== RStyle)
throw new TypeError('An RStyleArray should contain only RStyle elements');
});
Expand Down