empress / empress/broccoli-static-site-json
Pass custom options to serializer?
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 33
- Forks
- 8
- PR merge metrics
- No merged PRs in 30d
Description
Would you consider more freedom to customize the serializer, i.e. what gets passed as serializerOptions here. Maybe just another object you can pass that gets spread into serializerOptions?
My use case: I would like to use the transform function (see https://github.com/SeyZ/jsonapi-serializer#available-serialization-option-opts-argument) to convert a comma-separated list of values in a frontmatter attribute into a proper array in the JSON-API payload.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in lib/markdown-to-jsonapi.js at lines 38-45 and compare the current serializerOptions construction with the jsonapi-serializer options documentation. Confirm how a caller could provide the transform option, then verify that custom options reach serialization without changing existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- build-system, tooling
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100