static-cms/packages/netlify-cms-lib-util
Sam Lanning a47a29fb8b Allow for relative paths of media files (#2394)
* 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)
2019-08-24 16:03:09 -04:00
..
2019-08-24 13:57:37 -04:00

Docs coming soon!

Netlify CMS was recently converted from a single npm package to a "monorepo" of over 20 packages. That's over 20 Readme's! We haven't created one for this package yet, but we will soon.

In the meantime, you can:

  1. Check out the main readme or the documentation site for more info.
  2. Reach out to the community chat if you need help.
  3. Help out and write the readme yourself!