diff --git a/.eslintrc b/.eslintrc index 7abf4a5a..af1830c7 100644 --- a/.eslintrc +++ b/.eslintrc @@ -16,7 +16,7 @@ "rules": { "semi": ["error", "always"], "quotes": ["error", "single"], - "no-console": 0, + "no-console": 2, "no-param-reassign": 0, "react/jsx-filename-extension": 0, "import/no-extraneous-dependencies": 0, diff --git a/src/components/box/box.js b/src/components/box/box.js index ed773180..c9188300 100644 --- a/src/components/box/box.js +++ b/src/components/box/box.js @@ -23,13 +23,13 @@ export default class Box extends PureComponent { const { children, className, - style, renderAs, + ...props } = this.props; const Element = renderAs; return ( {children} diff --git a/src/components/breadcrumb/__test__/breadcrumb.test.js b/src/components/breadcrumb/__test__/breadcrumb.test.js index 98fd867e..5726a6cb 100644 --- a/src/components/breadcrumb/__test__/breadcrumb.test.js +++ b/src/components/breadcrumb/__test__/breadcrumb.test.js @@ -11,9 +11,11 @@ const Anchor = ({ describe('Breadcrumb component', () => { beforeEach(() => { + // eslint-disable-next-line no-console console.warn = jest.genMockFn(); }); afterAll(() => { + // eslint-disable-next-line no-console console.warn.mockRestore(); }); it('Should be a Breadcrumb', () => { diff --git a/src/components/breadcrumb/breadcrumb.js b/src/components/breadcrumb/breadcrumb.js index 9bc6ce45..4ec512a2 100644 --- a/src/components/breadcrumb/breadcrumb.js +++ b/src/components/breadcrumb/breadcrumb.js @@ -35,21 +35,22 @@ export default class Breadcrumb extends PureComponent { render() { const { className, - style, items, renderAs, hrefAttr, separator, size, align, + ...props } = this.props; if (renderAs !== 'a' && !hrefAttr) { + // eslint-disable-next-line no-console console.warn('if renderAs is different the anchor (a), hrefAttr is required. Check Breadcrumb props'); } const Element = renderAs; return (