Skip to content

Fix issue incorrect paths for fonts. Add methods to Use relative paths. #95

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 100 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
100 commits
Select commit Hold shift + click to select a range
1834aef
Fix issue incorrect paths for fonts. Add methods to Use relative paths.
nikrou Jul 14, 2017
69f039c
Fix lint (spaces instead of tabs)
nikrou Jul 14, 2017
0bdb0b5
Fix missing tsloader return statement
ldiringer Jul 19, 2017
4f4b963
bug #102 Fix missing tsloader return statement (ldiringer)
weaverryan Jul 21, 2017
9efc3c2
Tagging with webpack 3.0
weaverryan Jul 21, 2017
62afb63
convert error into warning
robertfausk Jun 30, 2017
5ed6374
convert error into warning
robertfausk Jun 30, 2017
bdbbd84
fix issue in generated public path of manifest.json
robertfausk Jun 30, 2017
d8238c0
Reversing some of the changes we won't do for now, and adding the fai…
weaverryan Jul 13, 2017
afc8dae
Fixing a bug where @import CSS files were not put through the autopre…
weaverryan Jul 21, 2017
54b3ecb
Adding --keep-public-path to dev-server to allow you to fully control…
weaverryan Jul 13, 2017
5db706f
Refactor plugin configuration
davidmpaz Jul 17, 2017
27a3a83
bug #108 Fixing a bug where @import CSS files were not put through th…
weaverryan Jul 25, 2017
c662464
Allowing an absolute publicPath with dev-server, but showing a warning
weaverryan Jul 15, 2017
55010b1
minor #99 Refactor plugin configuration (davidmpaz)
weaverryan Jul 25, 2017
b8dc43e
Using real public path, though it doesn't look like it matters
weaverryan Jul 21, 2017
7878a14
Add EditorConfig file
Lyrkan Jul 20, 2017
f109b7c
fixing changelog typo
weaverryan Jul 21, 2017
ab801cf
Fixing a bug with webpack 3.4.0 with extra arg as an entry
weaverryan Jul 26, 2017
8f97fac
upgrading locked deps
weaverryan Jul 26, 2017
363dc09
feature #96 Relaxed public path requirements with dev-server (robertf…
weaverryan Jul 21, 2017
d7ca1c8
minor #104 Add an EditorConfig file (Lyrkan)
weaverryan Jul 21, 2017
892a8cc
bug #114 Fixing a bug with webpack 3.4.0 with extra arg as an entry (…
weaverryan Jul 26, 2017
0b3af03
Adding quotes... just in case there are spaces
weaverryan Jul 26, 2017
cd7ca2d
prepping changelog
weaverryan Jul 26, 2017
119654c
Tagging 0.12.0
weaverryan Jul 26, 2017
dab8385
Modify images/fonts loaders so a hash is always added to the name of …
Lyrkan Jul 22, 2017
34a354f
Use [hash:8] for images and fonts filenames instead of [hash]
Lyrkan Jul 26, 2017
90ea53d
bug #110 Always add a hash to the name of the files created by the de…
weaverryan Jul 27, 2017
04e9b9b
Add options callback to Encore.enablePostCssLoader()
Lyrkan Aug 4, 2017
13cfa28
Removing quotes to get Windows tests passing
weaverryan Jul 27, 2017
1907d5c
Adding tests for the logger and cleaning up a bit internally
weaverryan Jul 27, 2017
8e5b721
Forked typescript type checking
davidmpaz Jul 18, 2017
2a097bd
feature #130 Add options callback to Encore.enablePostCssLoader() (Ly…
weaverryan Aug 5, 2017
69530ea
Remove duplicate addPlugin test case
Lyrkan Aug 4, 2017
567deae
minor #116 Adding tests for the logger and cleaning up a bit internal…
weaverryan Aug 5, 2017
d6a6dfb
feature #101 Forked typescript type checking (davidmpaz)
weaverryan Aug 5, 2017
860b5ff
reversing pathinfo logic
weaverryan Aug 5, 2017
84523c6
minor #131 Remove duplicate addPlugin test case (Lyrkan)
weaverryan Aug 5, 2017
2ec4e18
Initializing the plugins key on babel, so you can call babelConfig.pl…
weaverryan Jul 21, 2017
481230a
bug #132 Reversing pathinfo logic to avoid extra comments (weaverryan)
weaverryan Aug 5, 2017
a6f1b31
Allow to disable the default image and font loaders
Lyrkan Jul 20, 2017
fc41567
minor #107 Initializing the plugins key on babel, so you can call bab…
weaverryan Aug 5, 2017
9680da5
Add options callback to Encore.enableLessLoader()
Lyrkan Aug 5, 2017
a15034f
feature #103 Allow to disable the default image and font loaders (Lyr…
weaverryan Aug 5, 2017
1cb21d2
feature #134 Add options callback to Encore.enableLessLoader() (Lyrkan)
weaverryan Aug 9, 2017
b4a4d11
Giving the user a nice, default postcss.config.js file
weaverryan Jul 21, 2017
18c6a34
updating changelog for 0.13.0
weaverryan Aug 9, 2017
b459ac9
Loader features refactor
davidmpaz Jul 17, 2017
0f06890
minor #106 Giving the user a nice, default postcss.config.js file (we…
weaverryan Aug 10, 2017
736545f
Tagging 0.13.0
weaverryan Aug 9, 2017
2086e1c
Add Encore.configureRuntimeEnvironment() and Encore.clearRuntimeEnvir…
Lyrkan Jul 26, 2017
bbe03c9
Remove some tests related to the public API proxy and improve some te…
Lyrkan Aug 5, 2017
f6e7e80
minor #123 Loader features refactor (davidmpaz)
weaverryan Aug 10, 2017
583b750
Modify file headers to 'Symfony Webpack Encore package'
Lyrkan Aug 10, 2017
c7fbebc
minor #115 Add Encore.configureRuntimeEnvironment() method to the pub…
weaverryan Aug 10, 2017
093fcfe
Add Encore.configureFilenames() method to the public API
Lyrkan Aug 10, 2017
a294d08
minor #138 Modify file headers to 'Symfony Webpack Encore package' (L…
weaverryan Aug 16, 2017
bf30abd
feature #137 Add Encore.configureFilenames() method to the public API…
weaverryan Aug 16, 2017
779bfb8
tweak comment
weaverryan Aug 16, 2017
d25a1b9
Intercept output during functional tests (fixes #47)
Lyrkan Aug 18, 2017
618b408
updating 0.14.0 CHANGELOG
weaverryan Aug 16, 2017
155c3aa
minor #143 Intercept Webpack output during functional tests (Lyrkan)
weaverryan Sep 2, 2017
7bd38c7
Tagging 0.14.0
weaverryan Aug 16, 2017
f76a9ed
Enforcing that the manifest keys NEVER start with "/"
weaverryan Jul 21, 2017
2ae5248
Add Preact preset (with preact-compat support)
Lyrkan Aug 21, 2017
e532cf5
softening to a warning
weaverryan Aug 10, 2017
75a1965
Feature configure manifest options
Aug 17, 2017
9dff784
Replace the usePreactCompat boolean by an object in Encore.enablePrea…
Lyrkan Sep 3, 2017
c1acc09
Merge pull request #105 from weaverryan/tighter-manifest-key-prefix
weaverryan Sep 13, 2017
e35b743
feature #142 Feature configure manifest options (Bruno BOUTAREL)
weaverryan Sep 2, 2017
7cb5ee1
Allow webp files to be built in the images directory
aeyoll Aug 24, 2017
1896a1d
Merge pull request #144 from Lyrkan/add-preact-preset
weaverryan Sep 13, 2017
269c19a
minor re-wording of jsdoc
weaverryan Sep 2, 2017
7f6f6de
Merge pull request #146 from aeyoll/fix-webp
weaverryan Sep 13, 2017
93bca98
Add various methods to configure default plugins
nikrou Oct 10, 2017
c67e827
Remove configureCleanWebpackPlugin and use cleanupOutputBeforeBuild a…
Lyrkan Sep 12, 2017
1570b16
Minor text changes
Lyrkan Sep 13, 2017
e0b4f91
Add a 'Did you mean ...' error message for unrecognized API methods
Lyrkan Aug 30, 2017
ee50df5
Add "or method" to the "Did you mean ..." error message
Lyrkan Aug 31, 2017
81a945c
Only add the "Did you mean" message if the levenshtein distance is le…
Lyrkan Sep 13, 2017
e96f6ab
feature #152 Add various methods to configure default plugins (Lyrkan)
weaverryan Sep 14, 2017
ea99ae7
feature #150 Add a 'Did you mean ...' error message in case of an unr…
weaverryan Sep 14, 2017
1feed31
Replace sass option 'resolve_url_loader' by 'resolveUrlLoader'
Lyrkan Sep 13, 2017
8c4ee01
updating CHANGELOG for 0.15.0
weaverryan Sep 14, 2017
d52c02f
Add a logger.deprecation(message) method
Lyrkan Sep 14, 2017
96d1cea
changing our similarity distance to match commonly used in Symfony core
weaverryan Sep 14, 2017
6483986
minor #159 Replace "resolve_url_loader" by "resolveUrlLoader" (Lyrkan)
weaverryan Sep 14, 2017
05f640c
Fix JS query string versioning when using addStyleEntry
Lyrkan Sep 15, 2017
f12bf7a
Tagging 0.15.0
weaverryan Sep 14, 2017
cb17d1a
Fix "__esModule is not a recognized property" error when using a webp…
Lyrkan Sep 25, 2017
3fea06c
bug #161 Fix JS query string versioning when using addStyleEntry (Lyr…
Lyrkan Sep 16, 2017
47dda79
bug #167 Fix "__esModule is not a recognized property" error (Lyrkan)
weaverryan Sep 25, 2017
48c8382
Updating CHANGELOG
weaverryan Sep 25, 2017
d1c4ec7
Fix temporary map file not deleted in production mode
Lyrkan Sep 29, 2017
a248739
Releasing 0.15.1
weaverryan Sep 25, 2017
102c129
Add an instance of DefinePlugin even in development mode
Lyrkan Oct 4, 2017
16d0522
bug #170 Fix temporary map files not being deleted in production mode…
Lyrkan Oct 2, 2017
213463b
Merge pull request #172 from Lyrkan/fix-define-plugin-development
weaverryan Oct 6, 2017
4024676
Fix conflict
nikrou Oct 10, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
; top-most EditorConfig file
root = true

; Unix-style newlines
[*]
end_of_line = LF

[*.js]
indent_style = space
indent_size = 4
trim_trailing_whitespace = true
insert_final_newline = true
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ module.exports = {
"node/no-unpublished-bin": "error",
"node/no-unpublished-require": "error",
"node/process-exit-as-throw": "error",
"header/header": [2, "block", {"pattern": "This file is part of the Symfony package"}]
"header/header": [2, "block", {"pattern": "This file is part of the Symfony Webpack Encore package"}]
}
};

66 changes: 65 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,72 @@
# CHANGELOG

## 0.15.1

* Fixed bug with using `?` in your versioning strategy with
`addStyleEntry` - #161 via @Lyrkan

* Fixed bug when using `webpack.config.babel.js` with ES6
imports - #167 via @Lyrkan

## 0.15.0

* Add support for [Preact](https://preactjs.com/) - #144 via @Lyrkan

* Added `Encore.configureManifestPlugin()` method - #142 via @Seikyo

* Added 5 new methods to configure plugins! #152 via @Lyrkan
* `Encore.configureDefinePlugin()`
* `Encore.configureExtractTextPlugin()`
* `Encore.configureFriendlyErrorsPlugin()`
* `Encore.configureLoaderOptionsPlugin()`
* `Encore.configureUglifyJsPlugin()`

## 0.14.0

* Added `Encore.configureFilenames()` so that you can fully control
the filename patterns for all types of files - #137 via @Lyrkan

* Added `Encore.configureRuntimeEnvironment()`, which is useful
if you need to require `webpack.config.js` from some non-Encore
process (e.g. Karma) - #115 via @Lyrkan

## 0.13.0

* [BEHAVIOR CHANGE] Image and font files now *always* include
a hash in their filename, and the hash is shorter - #110 via @Lyrkan

* Fixed a bug that caused extra comments to be in the final production
compiled JavaScript - #132 via @weaverryan

* `Encore.enablePostCssLoader()` now accepts an options callback -
#130 via @Lyrkan

* `Encore.enableLessLoader()` now accepts an options callback -
#134 via @Lyrkan

* Added `Encore.enableForkedTypeScriptTypesChecking()` to enable
[fork-ts-checker-webpack-plugin](https://github.com/Realytics/fork-ts-checker-webpack-plugin)
for faster typescript type checking - #101 via @davidmpaz

* Added `Encore.disableImagesLoader()` and `Encore.disableFontsLoader()`
to totally disable the `file-loader` rules for images and fonts -
#103 via @Lyrkan

## 0.12.0

* Fixed a bug with webpack 3.4.0 ("Can't resolve dev") - #114.

* Added `--keep-public-path` option to `dev-server` that allows
you to specify that you do *not* want your `publicPath` to
automatically point at the dev-server URL. Also relaxed the
requirements when using `dev-server` so that you *can* now
specify a custom, fully-qualified `publicPath` URL - #96

* Fixed bug where `@import` CSS wouldn't use postcss - #108

## 0.11.0

* The `webpack` page was upgraded from version 2.2 to 3.1 #53. The
* The `webpack` package was upgraded from version 2.2 to 3.1 #53. The
`extract-text-webpack-plugin` package was also upgraded from
2.1 to 3.0.

Expand Down
8 changes: 5 additions & 3 deletions bin/encore.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env node
/*
* This file is part of the Symfony package.
* This file is part of the Symfony Webpack Encore package.
*
* (c) Fabien Potencier <[email protected]>
*
Expand All @@ -10,13 +10,12 @@

'use strict';

const path = require('path');
const parseRuntime = require('../lib/config/parse-runtime');
const context = require('../lib/context');
const chalk = require('chalk');

const runtimeConfig = parseRuntime(
require('yargs').argv,
require('yargs/yargs')(process.argv.slice(2)).argv,
process.cwd()
);
context.runtimeConfig = runtimeConfig;
Expand Down Expand Up @@ -62,11 +61,14 @@ function showUsageInstructions() {
console.log('Commands:');
console.log(` ${chalk.green('dev')} : runs webpack for development`);
console.log(' - Supports any webpack options (e.g. --watch)');
console.log();
console.log(` ${chalk.green('dev-server')} : runs webpack-dev-server`);
console.log(` - ${chalk.yellow('--host')} The hostname/ip address the webpack-dev-server will bind to`);
console.log(` - ${chalk.yellow('--port')} The port the webpack-dev-server will bind to`);
console.log(` - ${chalk.yellow('--hot')} Enable HMR on webpack-dev-server`);
console.log(` - ${chalk.yellow('--keep-public-path')} Do not change the public path (it is usually prefixed by the dev server URL)`);
console.log(' - Supports any webpack-dev-server options');
console.log();
console.log(` ${chalk.green('production')} : runs webpack for production`);
console.log(' - Supports any webpack options (e.g. --watch)');
console.log();
Expand Down
1 change: 1 addition & 0 deletions fixtures/css/imports_autoprefixer.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@import "autoprefixer_test.css";
17 changes: 17 additions & 0 deletions fixtures/css/same_filename.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
h4 {
background: top left url('./../images/symfony_logo.png') no-repeat;
}

h5 {
background: top left url('./../images/same_filename/symfony_logo.png') no-repeat;
}

@font-face {
font-family: 'Roboto';
src: url('./../fonts/Roboto.woff2') format('woff2');
}

@font-face {
font-family: 'Roboto2';
src: url('./../fonts/same_filename/Roboto.woff2') format('woff2');
}
9 changes: 9 additions & 0 deletions fixtures/css/style_with_fonts.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
$font-path: '../fonts';

@font-face {
font-family: 'Roboto';
src:url('#{$font-path}/Roboto.woff2') format('woff2'),
url('#{$font-path}/Roboto.svg') format('svg');
font-weight: normal;
font-style: normal;
}
Loading