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
image: my/nodejs-dockerfile | |
stages: | |
- test | |
- build | |
- deploy | |
before_script: | |
- ln -s /node_modules node_modules | |
- npm set progress=false |
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
concurrent = 1 | |
check_interval = 0 | |
[[runners]] | |
name = "secret" | |
url = "secret" | |
token = "secret" | |
executor = "docker" | |
environment = ["NODE_ENV=development"] | |
[runners.ssh] |
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 webpack = require('webpack') | |
const HtmlWebpackPlugin = require('html-webpack-plugin') | |
const loaders = require('./loaders.js') | |
module.exports = { | |
bail: true, | |
target: 'web', | |
entry: './app/client.js', |
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 webpack = require('webpack'); | |
const CaseSensitivePathsPlugin = require('case-sensitive-paths-webpack-plugin') | |
const HtmlWebpackPlugin = require('html-webpack-plugin') | |
const loaders = require('./loaders.js') | |
module.exports = { | |
entry: [ | |
require.resolve('webpack-dev-server/client') + '?/', |
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
module.exports = [ | |
{ | |
test: /\.jsx?$/, | |
loader: 'babel', | |
}, | |
{ | |
test: /\.css$/, | |
loader: 'style-loader!css-loader', | |
}, | |
{ |
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 App = observer(({ store }) => { | |
const { authenticated } = store | |
if (!authenticated ) { | |
return <Login | |
doLogin={store.login} | |
postLogin={store.showHomepage} | |
/> | |
} |
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
image: node:7.7.1 | |
stages: | |
- test | |
before_script: | |
- npm set progress=false | |
- npm install > npm-install.log 2>&1 | |
transaction testing: |
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 { useEffect, useRef, useState } from 'react'; | |
export default function AjaxToggle() { | |
const [checked, setChecked] = useState(false); | |
const firstRender = useRef(true); | |
function syncWithServer(checked) { | |
// ... | |
} |
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
# CSS-in-JS | |
## Avoid facepaint, just use object syntax. | |
{ | |
color: `blue`, | |
[mq.large]: { | |
color: `red`, | |
}, | |
} |
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
SPOTIFY_CLIENT_ID=xxxxxxxxxxxxxxxxxxxxxxxx | |
SPOTIFY_CLIENT_SECRET=xxxxxxxxxxxxxxxxxxxxxxxxxx | |
SPOTIFY_REFRESH_TOKEN=aaaaaaaaaaaaaaaa-bbbbbbbbbbbbbbbb-cccccccccccccccc-dddddddddddddddd-eeeeeeeeeeeeeeee |
OlderNewer