Moved to https://github.com/Kasu/react-distributed-batching
This file contains hidden or 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
"use strict"; | |
function jsonToSassVars (obj, indent) { | |
// Make object root properties into sass variables | |
var sass = ""; | |
for (var key in obj) { | |
sass += "$" + key + ":" + JSON.stringify(obj[key], null, indent) + ";\n"; | |
} | |
// Store string values (so they remain unaffected) |
This file contains hidden or 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 {FuseBox, EnvPlugin, QuantumPlugin, WebIndexPlugin, CopyPlugin, CSSPlugin, ImageBase64Plugin} from "fuse-box"; | |
const isProduction: boolean = false; | |
const fuse = FuseBox.init({ | |
homeDir: "src", | |
sourceMaps: isProduction ? undefined : {project: true, vendor: false}, | |
hash: isProduction, | |
target: "browser@es2015", | |
output: "dist/$name.js", | |
alias: { |
This file contains hidden or 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
Show hidden characters
{ | |
"exclude": [ | |
"node_modules", | |
"**/*.test.*" | |
], | |
"compilerOptions": { | |
"baseUrl": ".", | |
"experimentalDecorators": true, | |
"sourceMap": true, | |
"noImplicitAny": true, |
This file contains hidden or 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 fuse = FuseBox.init({ | |
homeDir: "app", | |
sourceMaps: {project: options.sourceMaps, vendor: false}, | |
hash: options.hashFilenames, | |
modulesFolder: "app", | |
alias: { | |
src: "~/src/", | |
config: "~/config/" | |
}, | |
target: "browser@es2017", |
This file contains hidden or 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 { | |
FuseBox, EnvPlugin, QuantumPlugin, WebIndexPlugin, CSSPlugin, | |
JSONPlugin, Sparky, File, CopyPlugin, WorkFlowContext, BabelPlugin | |
} from "fuse-box"; | |
import {BuildOptions, getCommonBuildOptions, getEnvironments, NodeEnv, OcastEnv} from "./BuildOptions"; | |
/** | |
* Sets up a FuseBox ready to either run a development server or produce builds. | |
* All required configuration is already hardcoded in this function. | |
* You may however choose to pass in additional options to customize your dev or build experience to your liking. |
This file contains hidden or 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
export enum NodeEnv { | |
Production = "production", | |
Development = "development" | |
} | |
export enum OcastEnv { | |
Altair = "altair", | |
Development = "development", | |
Staging = "stage", | |
Production = "production" |
This file contains hidden or 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 path = require("path"); | |
import * as webpack from "webpack"; | |
import {getCommonBuildOptions, getEnvironments} from "./BuildOptions"; | |
import {HotModuleReplacementPlugin, LoaderOptionsPlugin, NamedModulesPlugin} from "webpack"; | |
import CommonsChunkPlugin = webpack.optimize.CommonsChunkPlugin; | |
const {BundleAnalyzerPlugin} = require("webpack-bundle-analyzer"); | |
const ExtractTextPlugin = require("extract-text-webpack-plugin"); | |
const HtmlWebpackPlugin = require("webpack-html-plugin"); | |
const fileLoader = { |
This file contains hidden or 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
new AutoDllPlugin({ | |
inject: true, | |
debug: true, | |
filename: '[name].dll.js', | |
entry: { | |
vendor: Object.keys(JSON.parse(fs.readFileSync('./package.json', 'utf8')).dependencies) | |
} | |
}) |
This file contains hidden or 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
function test (target: any, propertyKey?: string) { | |
debugger; | |
} | |
class App { | |
@test foo = 'bar'; | |
} |
OlderNewer