Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Having human-readable times that are not associated with dates is
frequently useful. For example, this lets you say things like:
Using the ISO 8061 time formats should make it easy for both
people and software to interact with the values.
Since Swagger-specified APIs are often consumed and produced from
JavaScript, and since JavaScript has limited time-handling
capabilities, I thought I'd dig a bit deeper in that direction.
Support for date-less ISO 8601 times in native JavaScript is unclear,
but Firefox 31.5 in seems to support times with a 'T' prefix:
which, in conjunction with Date.prototype.toTimeString() and other
time-specific maniplations is probably sufficient for most purposes.
Chromium 41.0, on the other hand, gave 'Invalid Date' warnings for
each of those cases, so JavaScript consumers may want to pad their
times with dummy date information. Moment.js also requires a date
part and doesn't support stand-alone times.
On the other hand, there are time-only pickers in JavaScript.
Python also has a time-only format as does Java. Go just
has a date-time type, but it can parse time-only strings.