Skip to content

Commit

Permalink
Remove old eslint-ignores from unstable_ prefix (#10740)
Browse files Browse the repository at this point in the history
  • Loading branch information
ijjk committed Feb 28, 2020
1 parent 3bfb650 commit b262401
Show file tree
Hide file tree
Showing 23 changed files with 0 additions and 30 deletions.
2 changes: 0 additions & 2 deletions packages/next/export/worker.js
Expand Up @@ -118,9 +118,7 @@ export default async function({
let curRenderOpts = {}
let renderMethod = renderToHTML

// eslint-disable-next-line camelcase
const renderedDuringBuild = getStaticProps => {
// eslint-disable-next-line camelcase
return !buildExport && getStaticProps && !isDynamicRoute(path)
}

Expand Down
Expand Up @@ -10,7 +10,6 @@ export default class UrlPropChange extends React.Component {
}
}

// eslint-disable-next-line camelcase
componentDidUpdate(prevProps) {
if (prevProps.url !== this.props.url) {
this.setState(() => {
Expand Down
1 change: 0 additions & 1 deletion test/integration/getserversideprops/pages/another/index.js
Expand Up @@ -2,7 +2,6 @@ import Link from 'next/link'
import fs from 'fs'
import findUp from 'find-up'

// eslint-disable-next-line camelcase
export async function getServerSideProps() {
const text = fs
.readFileSync(
Expand Down
@@ -1,7 +1,6 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ query }) {
return {
props: {
Expand Down
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ params }) {
if (params.post === 'post-10') {
await new Promise(resolve => {
Expand Down
1 change: 0 additions & 1 deletion test/integration/getserversideprops/pages/blog/index.js
@@ -1,7 +1,6 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getServerSideProps() {
return {
props: {
Expand Down
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ params }) {
return {
props: {
Expand Down
@@ -1,6 +1,5 @@
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getServerSideProps() {
return {
props: {
Expand Down
1 change: 0 additions & 1 deletion test/integration/getserversideprops/pages/index.js
@@ -1,6 +1,5 @@
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getServerSideProps() {
return {
props: {
Expand Down
1 change: 0 additions & 1 deletion test/integration/getserversideprops/pages/invalid-keys.js
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ params, query }) {
return {
world: 'world',
Expand Down
1 change: 0 additions & 1 deletion test/integration/getserversideprops/pages/something.js
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ params, query }) {
return {
props: {
Expand Down
@@ -1,7 +1,6 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getServerSideProps({ query }) {
return {
props: {
Expand Down
@@ -1,11 +1,9 @@
import React from 'react'

// eslint-disable-next-line camelcase
export async function getStaticPaths() {
return { paths: [{ params: { slug: 'hello' } }], fallback: true }
}

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down
@@ -1,11 +1,9 @@
import React from 'react'

// eslint-disable-next-line camelcase
export async function getStaticPaths() {
return { paths: [{ foo: 'bad', baz: 'herro' }], fallback: true }
}

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down
2 changes: 0 additions & 2 deletions test/integration/prerender-legacy/pages/blog/[post].js
@@ -1,11 +1,9 @@
import React from 'react'

// eslint-disable-next-line camelcase
export async function unstable_getStaticParams() {
return ['/blog/post-1']
}

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down
1 change: 0 additions & 1 deletion test/integration/prerender/pages/another/index.js
Expand Up @@ -2,7 +2,6 @@ import Link from 'next/link'
import fs from 'fs'
import findUp from 'find-up'

// eslint-disable-next-line camelcase
export async function getStaticProps() {
const text = fs
.readFileSync(
Expand Down
2 changes: 0 additions & 2 deletions test/integration/prerender/pages/blog/[post]/[comment].js
@@ -1,7 +1,6 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getStaticPaths() {
return {
paths: [
Expand All @@ -12,7 +11,6 @@ export async function getStaticPaths() {
}
}

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down
2 changes: 0 additions & 2 deletions test/integration/prerender/pages/blog/[post]/index.js
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getStaticPaths() {
return {
paths: [
Expand All @@ -19,7 +18,6 @@ export async function getStaticPaths() {

let counter = 0

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
if (params.post === 'post-10') {
await new Promise(resolve => {
Expand Down
1 change: 0 additions & 1 deletion test/integration/prerender/pages/blog/index.js
@@ -1,7 +1,6 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getStaticProps() {
return {
props: {
Expand Down
1 change: 0 additions & 1 deletion test/integration/prerender/pages/default-revalidate.js
@@ -1,6 +1,5 @@
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getStaticProps() {
return {
props: {
Expand Down
1 change: 0 additions & 1 deletion test/integration/prerender/pages/index.js
@@ -1,6 +1,5 @@
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getStaticProps() {
// throw new Error('oops from getStaticProps')
return {
Expand Down
1 change: 0 additions & 1 deletion test/integration/prerender/pages/something.js
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down
2 changes: 0 additions & 2 deletions test/integration/prerender/pages/user/[user]/profile.js
@@ -1,12 +1,10 @@
import React from 'react'
import Link from 'next/link'

// eslint-disable-next-line camelcase
export async function getStaticPaths() {
return { paths: [], fallback: true }
}

// eslint-disable-next-line camelcase
export async function getStaticProps({ params }) {
return {
props: {
Expand Down

0 comments on commit b262401

Please sign in to comment.