Skip to content
This repository has been archived by the owner on Jul 19, 2021. It is now read-only.

Commit

Permalink
Merge pull request #654 from Shopify/dont-require-fonts
Browse files Browse the repository at this point in the history
Fix build break when missing fonts directory
  • Loading branch information
t-kelly authored Jun 26, 2018
2 parents 2e38e35 + 5f5553c commit ad61c6e
Showing 1 changed file with 28 additions and 26 deletions.
54 changes: 28 additions & 26 deletions packages/slate-tools/tools/webpack/config/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,32 +133,34 @@ module.exports = {

extractLiquidStyles,

new CopyWebpackPlugin([
{
from: paths.svgs,
to: `${paths.snippets.dist}/[name].liquid`,
},
{
from: paths.static.src,
to: paths.static.dist,
},
{
from: paths.images.src,
to: paths.images.dist,
},
{
from: paths.fonts.src,
to: paths.fonts.dist,
},
{
from: paths.locales.src,
to: paths.locales.dist,
},
{
from: paths.settings.src,
to: paths.settings.dist,
},
]),
new CopyWebpackPlugin(
[
{
from: paths.svgs,
to: `${paths.snippets.dist}/[name].liquid`,
},
{
from: paths.static.src,
to: paths.static.dist,
},
{
from: paths.images.src,
to: paths.images.dist,
},
{
from: paths.fonts.src,
to: paths.fonts.dist,
},
{
from: paths.locales.src,
to: paths.locales.dist,
},
{
from: paths.settings.src,
to: paths.settings.dist,
},
].filter((directory) => fs.existsSync(directory.from)),
),

new WriteFileWebpackPlugin({
test: /^(?:(?!hot-update.json$).)*\.(liquid|json)$/,
Expand Down

0 comments on commit ad61c6e

Please sign in to comment.