Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
cd path/to/app
yarn # or npm iyarn dev
# or
npm run devyarn dev -p <some other port> # e.g. yarn dev -p 3001├── .github
| ├── contributing.md
├── __tests__
| ├── Home-es.test.tsx
| ├── Home-fr.test.tsx
| ├── Home.test.tsx
├── config
| ├── i18n
│ │ ├── config.ts
| ├── jest
│ │ ├── cssTransform.js
│ │ ├── test-utils.tsx
| ├── seo
│ │ ├── next-seo.config.ts
| ├── app.config.ts
├── public
│ ├── locales
| | ├── en
| | | ├── common.json
| | | ├── footer.json
| | | ├── header.json
| | | ├── index.json
| | ├── es
| | | ├── common.json
| | | ├── footer.json
| | | ├── header.json
| | | ├── index.json
| | ├── fr
| | | ├── common.json
| | | ├── footer.json
| | | ├── header.json
| | | ├── index.json
│ ├── android-chrome-192x192.png
│ ├── android-chrome-512x512.png
│ ├── apple-touch-icon.png
│ ├── favicon-16x16.png
│ ├── favicon-32x32.png
│ ├── favicon.ico
│ ├── site.webmanifest
│ ├── vercel.svg
├── src
| ├── components
│ │ ├── layout
| | | ├── Footer.tsx
| | | ├── Header.tsx
| | | ├── WebApp.tsx
│ │ ├── App.tsx
│ ├── i18n
│ │ ├── create-provider
| | | ├── browser.tsx
| | | ├── index.tsx
| ├── lib
│ │ ├── types.ts
│ │ ├── utils.ts
│ ├── pages
│ │ ├── [lng]
| | | ├── index.tsx
│ │ ├── api
| | | ├── hello.ts
│ │ ├── 404.tsx
│ │ ├── _app.tsx
│ │ ├── _document.tsx
│ │ ├── _error.tsx
│ │ ├── index.tsx
├── styles
| ├── Footer.module.scss
│ ├── Header.module.scss
| ├── Home.module.scss
│ ├── index.css
├── .babelrc
├── .editorconfig
├── .env.development
├── .env.production
├── .gitignore
├── CODE_OF_CONDUCT.md
├── README.md
├── changelog.md
├── jest.config.js
├── license.md
├── next-env.d.ts
├── next.config.js
├── package.json
├── postcss.config.js
├── tailwind.config.js
├── tsconfig.json
└── yarn.locki18nConfig.defaultLnggetLocaleDataForStaticPropssrc/pages/_app.tsx
// import App from "next/app";
import type { AppProps /*, AppContext */ } from "next/app";
import Head from "next/head";
import I18n from "i18n/create-provider";
import App from "components/App";
import "styles/index.css";
function MyApp(props: AppProps) {
return (
<>
<Head>
<meta
name="viewport"
content="minimum-scale=1, initial-scale=1, width=device-width, shrink-to-fit=no, user-scalable=no, viewport-fit=cover"
/>
</Head>
<I18n
requiredNS={props.pageProps.requiredNS}
lng={props.pageProps.lng}
lngDict={props.pageProps.lngDict}
>
<App {...props} />
</I18n>
</>
);
}
// Only uncomment this method if you have blocking data requirements for
// every single page in your application. This disables the ability to
// perform automatic static optimization, causing every page in your app to
// be server-side rendered.
//
// MyApp.getInitialProps = async (appContext: AppContext) => {
// // calls page's `getInitialProps` and fills `appProps.pageProps`
// const appProps = await App.getInitialProps(appContext);
// return { ...appProps }
// }
export default MyApp;