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
Generate icons using electron-icon-maker #2659
Comments
The electron-icon-maker requires a png file with a recommended size of 1024x1024 at least as input. |
How do you want this to work exactly? A Webpack plugin? Here is an icon processing plugin, I'm willing to give this a try. It's a good way to learn Webpack. |
No, not an icon font. It's for the app icon. App icons are usually or mostly created as an SVG file. A Webpack plug-in could convert them into necessary icon files like PNG or .ico. For icon fonts I am already using another Webpack plugin. |
Sorry for the confusion. The font plugin is an example I would use to get the icon maker to run. Would you like the icon maker to be called from a Webpack plugin is my question. If so I can work on this. |
Maybe an npm script would be the better way. What if you use Webpack with hot reload and the icons will be created everytime you edit the source code? This could cost unnecessary runtime. But if it's only a few milliseconds, then it doesn't matter. |
I changed my mind. The icons could be created when creating the main js. (config file: |
Let me do some research on this and I will post something next week. |
@lazytyper I created a POC repo and was able to get icon maker code to run with a Webpack plugin. I used a forked version of this plugin to run it with Webpack 5. Do you want me to post the project so you can see how it works? I'm not sure if I want to use this particular plugin, I want a plugin to run once on build, this does but it has a watch. I don't think we need a watch. This might work better. |
@kbrisso Sorry for the late answer. I've just been trying the webpack plugins by myself, I also tried I also discovered that I can try another way without Webpack:
|
@lazytyper No worries about reply everyone is busy..I modified the source of icon maker and did get it to work in a plugin. Not the best approach but I did get it to work, I can post code later. That being said from reading above post you want to use like to try another processor jimp or node-svg2img. I do think we can make something work in a plugin but I think it should be an optional feature to run because of the processing. Let me know what project you prefer and I can try and make something work. I 'm new to Webpack and this is a good exercise. My thinking is if we can get this to to work the configuration could be used for other pre-processing type stuff. |
https://github.com/jaretburkett/electron-icon-maker
The text was updated successfully, but these errors were encountered: