diff --git a/.eslintrc.js b/.eslintrc.js index e57f7f0d48..f9fcb20d1a 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -14,6 +14,7 @@ module.exports = { argsIgnorePattern: '^event$', ignoreRestSiblings: true, vars: 'all', + varsIgnorePattern: 'jsx|emotionJSX' }, ], curly: [2, 'multi-line'], diff --git a/docs/App/Footer.js b/docs/App/Footer.js index 3ce938b2d2..be740670be 100644 --- a/docs/App/Footer.js +++ b/docs/App/Footer.js @@ -1,6 +1,7 @@ // @flow - -import React, { type Node } from 'react'; +/** @jsx jsx */ +import { type Node } from 'react'; +import { jsx } from '@emotion/core'; // const smallDevice = '@media (max-width: 769px)'; const largeDevice = '@media (min-width: 770px)'; diff --git a/docs/App/GitHubButton.js b/docs/App/GitHubButton.js index 689ee433b8..01ffae7ac4 100644 --- a/docs/App/GitHubButton.js +++ b/docs/App/GitHubButton.js @@ -1,6 +1,6 @@ // @flow - -import React from 'react'; +/** @jsx jsx */ +import { jsx } from '@emotion/core'; type Props = { count: number, repo: string }; diff --git a/docs/App/Header.js b/docs/App/Header.js index 4bab0d8770..3a7dd0e829 100644 --- a/docs/App/Header.js +++ b/docs/App/Header.js @@ -1,7 +1,8 @@ // @flow - +/** @jsx jsx */ import fetch from 'unfetch'; -import React, { Component, type Node } from 'react'; +import { Component, type Node } from 'react'; +import { jsx } from '@emotion/core'; import { withRouter } from 'react-router-dom'; import Select from '../../src'; diff --git a/docs/App/PageNav.js b/docs/App/PageNav.js index 63f9ad3fa9..54502291ce 100644 --- a/docs/App/PageNav.js +++ b/docs/App/PageNav.js @@ -1,6 +1,7 @@ // @flow - -import React, { Component, type ElementRef } from 'react'; +/** @jsx jsx */ +import { Component, type ElementRef } from 'react'; +import { jsx } from '@emotion/core'; import { Route, Switch } from 'react-router-dom'; import type { RouterProps } from '../types'; diff --git a/docs/App/TwitterButton.js b/docs/App/TwitterButton.js index f759b3c322..1721ca0b9e 100644 --- a/docs/App/TwitterButton.js +++ b/docs/App/TwitterButton.js @@ -1,6 +1,6 @@ // @flow - -import React from 'react'; +/** @jsx jsx */ +import { jsx } from '@emotion/core'; const TwitterButton = () => (