Skip to content

Instantly share code, notes, and snippets.

View zlsun's full-sized avatar

zlsun zlsun

  • China
View GitHub Profile
@zlsun
zlsun / webpack.config.js
Created January 14, 2016 17:55 — forked from alexesDev/webpack.config.js
React Native + Webpack (with babel6 and react-native v0.17)
var path = require('path');
var webpack = require('webpack');
var reactNativeExternalsPromise = (function () {
var reactNativeRoot = path.dirname(require.resolve('react-native/package'));
var blacklist = require('react-native/packager/blacklist');
var ReactPackager = require('react-native/packager/react-packager');
const rnEntryPoint = require.resolve('react-native');
return ReactPackager.getDependencies({

Usage

  1. npm install babel-loader imports-loader webpack --save
  2. Create webpack.config.js
  3. Move index.ios.js to src/index.ios.jsx
  4. webpack --watch

Example

src/index.ios.jsx

@zlsun
zlsun / vimura.md
Created January 11, 2016 13:04 — forked from vext01/vimura.md
Vim+Zathura+Synctex

Vim+Zathura+Synctex

  • In a script called 'vimura':
#!/bin/sh
echo $1
zathura -s -x "gvim --servername $1 -c \"let g:syncpdf='$1'\" --remote +%{line} %{input}" $*
@zlsun
zlsun / ignorelist
Last active August 29, 2015 14:27 — forked from rubo77/ignorelist
This ignorelist can be used to backup your home folder without useless folders and files, see http://askubuntu.com/a/545676/34298
#These directories may be excluded:
# contains mounted file systems
.gvfs
.local/share/gvfs-metadata
# contains the actual encrypted home directory
.Private
# session-specific
.dbus
.cache