Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
Unreleased
Added
#inspectand#to_sfor debugging.
Deprecated
.parse!will be removed in a future release. Use.parseinstead, and validate the result using#valid?and#errors.
0.5.0 - 2019-08-26
Added
Nodaire::IndentalandNodaire::Tablatalnow implementEnumerable, which allows you to iterate over the results with#each,#mapetc.- These classes also implement
[], so you can reference Indental data by category name, and Tablatal data by row index. - Convert Tablatal to JSON with
Nodaire::Tablatal#to_json.
Deprecated
#datawill be removed in a future release. Use#to_hand#to_ainstead.
0.4.0 - 2019-08-22
Added
- Support for Indental keys with blank values.
- Two string normalization methods are now public:
Nodaire.squeezeandNodaire.symbolize.
Changed
- Category names and keys are converted to upper case, except when
symbolize_namesis specified. - Any sequence of whitespace is converted into a space character. Punctuation is left intact.
symbolize_namesconverts any sequence of non-alphanumeric characters to_.
Fixed
- Indentation using tabs is now treated as an error.
0.3.0 - 2019-08-18
Added
Indental#categoriesreturns an array of category names.- Documentation!
Changed
- Strings are used for keys by default. To use symbols, pass the
symbolize_namesargument. - Category names and keys are normalised when detecting duplicates, and when
converting them to symbols. This involves converting to lowercase and
replacing each sequence of whitespace/underscores/dashes with
_. - Indental parser detects when the input is wrapped in a JS template string.
- Require Ruby >= 2.5.0. (Previously there was no minimum set, but it used a feature that required Ruby >= 2.6.0.)
0.2.0 - 2019-08-17
Added
- Parse Indental files, returning a hash or a JSON string.
#valid?and#errorsinstance methods.
Changed
.parsesilently ignores duplicate keys and other errors, instead of raising an exception. This is paired with a new.parse!method which does raise an exception.
0.1.0 - 2019-08-16
Added
- Parse Tablatal files, returning an array of hashes or a CSV string.