This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm install -S react-draft-wysiwyg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "react-scroll-up-btn", | |
"version": "1.0.3", | |
"description": "A simple scroll up button built with react", | |
"main": "./lib/ScrollUpButton.js", | |
"repository": { | |
"type": "git", | |
"url" : "https://github.com/weianofsteel/react-scroll-up-button" | |
}, | |
"keywords": [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
module.exports = { | |
mode: 'production', | |
entry: './src/ScrollUpButton.js', | |
output: { | |
path: path.resolve('lib'), | |
filename: 'ScrollUpButton.js', | |
libraryTarget: 'commonjs2', | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"presets": [ | |
"react", | |
"env", | |
"stage-0" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const NextI18Next = require('next-i18next').default | |
const localeSubpaths = require('next/config').default().publicRuntimeConfig | |
const path = require('path') | |
module.exports = new NextI18Next({ | |
defaultLanguage:'en', | |
otherLanguages: ['zhHant', 'fr', 'es'], | |
localeSubpaths:{ | |
zhHant:'cn', | |
fr: 'fr', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const NextI18Next = require('next-i18next').default | |
const localeSubpaths = require('next/config').default().publicRuntimeConfig | |
const path = require('path') | |
module.exports = new NextI18Next({ | |
defaultLanguage:'en', | |
otherLanguages: ['zhHant', 'fr', 'es'], | |
localePath: path.resolve('./public/static/locales') | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import App from 'next/app' | |
import React from 'react'; | |
import Head from 'next/head' | |
import { appWithTranslation } from '../i18n' | |
import '../css/main.css' | |
const MyApp = ({ Component, pageProps }) => { | |
return( | |
<React.Fragment> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react' | |
import Sample from '../../component/Sample' | |
import { withTranslation } from '../../i18n' | |
import PropTypes from 'prop-types' | |
const SamplePage = ({t}) => { | |
return( | |
<Sample/> | |
) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react' | |
import { i18n, withTranslation } from '../i18n' | |
import PropTypes from 'prop-types' | |
import TranslateIcon from '@material-ui/icons/Translate' | |
import { makeStyles } from '@material-ui/core/styles' | |
import MenuItem from '@material-ui/core/MenuItem'; | |
import FormControl from '@material-ui/core/FormControl'; | |
import Select from '@material-ui/core/Select'; | |
import Grid from '@material-ui/core/Grid' |
OlderNewer