Skip to content

Instantly share code, notes, and snippets.

View ofarukcaki's full-sized avatar

of ofarukcaki

View GitHub Profile
@ofarukcaki
ofarukcaki / next.config.js
Created January 23, 2019 21:17 — forked from balupton/next.config.js
next.js webpack configs
module.exports = {
webpack: (config) => {
const webpack = require('webpack')
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin
config.plugins = config.plugins || []
config.plugins.push(new webpack.ContextReplacementPlugin(/moment[/\\]locale$/, /en/))
config.plugins.push(new BundleAnalyzerPlugin())
return config
}
}

Option 1: Command-line download extension as zip and extract

extension_id=jifpbeccnghkjeaalbbjmodiffmgedin   # change this ID
curl -L -o "$extension_id.zip" "https://clients2.google.com/service/update2/crx?response=redirect&os=mac&arch=x86-64&nacl_arch=x86-64&prod=chromecrx&prodchannel=stable&prodversion=44.0.2403.130&x=id%3D$extension_id%26uc" 
unzip -d "$extension_id-source" "$extension_id.zip"

Thx to crxviewer for the magic download URL.

@ofarukcaki
ofarukcaki / default.md
Last active November 29, 2023 12:00
create-react-app with react-router Nginx 404 error solution in page refresh

You need to edit /etc/nginx/sites/available/default file

change the location part as follows

location / { try_files $uri $uri/ /index.html; }

lastly, refresh the Nginx with sudo servuce restart nginx

@ofarukcaki
ofarukcaki / notes.md
Created May 22, 2018 14:32 — forked from matthewjberger/notes.md
How to make an electron app using Create-React-App and Electron with Electron-Builder.

How to setup Shadowsocks on your Ubuntu server

Your school or company network may block the access to a few specific websites. To solve this problem, I'd highly recommend Shadowsocks, since it is the easiest proxy tool I've ever found, and it's FREE (of course iff you have your own server running).

First, ssh to your server, and make sure you have Python and pip installed. If you have Python but not pip, install it using the following command

$ sudo apt-get install python3-pip