forked from jantimon/favicons-webpack-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support string array for logo argument
favicons >= 7.0.0 picks source image by it's size, solves jantimon#265
- Loading branch information
Showing
4 changed files
with
411 additions
and
23 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import test from 'ava'; | ||
import * as path from 'path'; | ||
import FaviconsWebpackPlugin from '../src/index.js'; | ||
import { | ||
logo, | ||
generate, | ||
withTempDirectory, | ||
snapshotCompilationAssets, | ||
} from './_util.mjs'; | ||
|
||
withTempDirectory(test); | ||
|
||
test('should work with logo array', async (t) => { | ||
const dist = path.join(t.context.root, 'dist'); | ||
const compilationStats = await generate({ | ||
context: t.context.root, | ||
output: { | ||
path: dist, | ||
}, | ||
plugins: [new FaviconsWebpackPlugin({ logo: [logo] })], | ||
}); | ||
|
||
snapshotCompilationAssets(t, compilationStats); | ||
}); |
Oops, something went wrong.