
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
exif-loader
Advanced tools
Extract EXIF- & IPTC-data from your JPGs during build-time.
npm install --save-dev exif-loader
You can use the EXIF-loader as a standalone loader:
webpack.config.js
module.exports = {
module: {
rules: [
{
test: /\.jpg$/,
use: ['exif-loader'],
},
],
},
};
modules/a.js
import { exif, iptc } from './some-image.jpg';
const { imageWidth } = exif.image;
const { object_name } = iptc;
You can also use the load in tandem with the file-loader.
webpack.config.js
module.exports = {
module: {
rules: [
{
test: /\.jpg$/,
oneOf: [
{
resourceQuery: /^\?exif$/,
use: 'exif-loader',
},
{
resourceQuery: /^\?file$/,
use: ['file-loader'],
},
],
},
],
},
};
modules/b.js
import { exif, iptc } from './some-image.jpg?exif';
import file from './some-image.jpg?file';
const { imageWidth } = exif.image;
const { object_name } = iptc;
export default function () {
return (
<figure>
<img src={file} width={imageWidth} alt="" />
<figcaption>{object_name}</figcaption>
</figure>
);
}
If you stumbled upon a bug or have an idea for improvements, feel free to open an issue.
If you want to contribute code, you're highly welcome to open a pull-request. Please use a feature-branch for that and make sure, the CI-test is green.
Thanks!
I you have questions, feel free to ping me on twitter: @Herschel_R.
The MIT License (MIT)
Copyright (c) 2020 Emanuel Kluge
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
FAQs
EXIF metadata loader module for Webpack.
The npm package exif-loader receives a total of 3 weekly downloads. As such, exif-loader popularity was classified as not popular.
We found that exif-loader demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.