a47a29fb8b
* Allow for relative paths of media files fixes #325 * Switch to calculating the relative path based on collection The required relative path is now calculated depending on the location of the collection of the current entry having the media inserted into. And the configuration option has now been changed to a boolean flag. This allows collections to not neccesarily all be in the same location relative to the media folder, and simplifies config. * Clean up code and fix linting * Add unit tests to resolveMediaFilename() * Rework insertMedia action to fetch own config This moves more of the media path resolution logic into the action which makes it easier to unit test * Add unit tests for the mediaLibrary.insertMedia action * yarn run format * add dependabot config (#2580)
29 lines
864 B
JSON
29 lines
864 B
JSON
{
|
|
"name": "netlify-cms-lib-util",
|
|
"description": "Shared utilities for Netlify CMS.",
|
|
"version": "2.4.0-beta.1",
|
|
"repository": "https://github.com/netlify/netlify-cms/tree/master/packages/netlify-cms-lib-util",
|
|
"bugs": "https://github.com/netlify/netlify-cms/issues",
|
|
"module": "dist/esm/index.js",
|
|
"main": "dist/netlify-cms-lib-util.js",
|
|
"license": "MIT",
|
|
"keywords": [
|
|
"netlify-cms"
|
|
],
|
|
"sideEffects": false,
|
|
"scripts": {
|
|
"develop": "yarn build:esm --watch",
|
|
"build": "cross-env NODE_ENV=production webpack",
|
|
"build:esm": "cross-env NODE_ENV=esm babel src --out-dir dist/esm --ignore \"**/__tests__\" --root-mode upward"
|
|
},
|
|
"dependencies": {
|
|
"get-relative-path": "^1.0.2",
|
|
"js-sha256": "^0.9.0",
|
|
"localforage": "^1.7.3"
|
|
},
|
|
"peerDependencies": {
|
|
"immutable": "^3.7.6",
|
|
"lodash": "^4.17.11"
|
|
}
|
|
}
|