Compare commits
No commits in common. "c05fd94028d6023b3d4debf0c1d2bece2c547df5" and "9e136fa1b390731536f9888d17c6ce9b911f43c8" have entirely different histories.
c05fd94028
...
9e136fa1b3
@ -48,7 +48,6 @@ let
|
||||
name,
|
||||
src,
|
||||
nodePackages ? null,
|
||||
routes ? [ "/" ],
|
||||
}:
|
||||
let
|
||||
nodeSource = symlinkJoin {
|
||||
@ -57,12 +56,6 @@ let
|
||||
builderPkg.lib
|
||||
] ++ (if nodePackages != null then [ nodePackages ] else [ ]);
|
||||
};
|
||||
|
||||
baseWebpackConfig = builtins.readFile ./webpack.config.js;
|
||||
webpackConfig = ''
|
||||
const ROUTES = ${builtins.toJSON routes}
|
||||
'' + "\n" + baseWebpackConfig;
|
||||
webpackConfigFile = pkgs.writeText "${name}-webpack-config" webpackConfig;
|
||||
in
|
||||
stdenv.mkDerivation {
|
||||
inherit name;
|
||||
@ -77,7 +70,6 @@ let
|
||||
|
||||
patchPhase = ''
|
||||
ln -sf ${nodeSource}/node_modules .
|
||||
cp ${webpackConfigFile} webpack.config.js
|
||||
'';
|
||||
|
||||
shellHook = ''
|
||||
|
@ -1,3 +1,5 @@
|
||||
const ROUTES = ['/', '/about', '/404', '/posts', '/posts/viveahk', '/posts/librebasics']
|
||||
|
||||
const path = require('path')
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin')
|
||||
const PrerenderSPAPlugin = require('prerender-spa-plugin')
|
||||
|
Loading…
Reference in New Issue
Block a user