drafter
drafter copied to clipboard
API Blueprint Parser (C++)
``` FORMAT: 1A HOST: http://example.com # Example API # Group Test ## Order Collection [/example] ### GET + Response 200 (application/json) + Attributes (EnumTest) # Data Structures ## EnumTest (object)...
I saw "warning" while bulding only drafter-cli, the compilation contiues and appears to work though. ``` [78/79] Linking CXX static library src/libdrafter.a /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: src/libdrafter.a(MsonMemberToApie.cc.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file:...
Suppose such doc: ``` # My API # Data Structures # Plan + kind (string) + Sample: free ``` Drafter generates such AST for samples section ``` samples: element: "array"...
"## [/resourcename]" shows "valid document" but the resulting code doesn't work properly in the documentation, ie no machine column or console
``` ../drafter/ext/snowcrash/src/UriTemplateParser.cc:82:16: warning: local variable 'variableExpression' will be copied despite being returned by name [-Wreturn-std-move] return variableExpression; ^~~~~~~~~~~~~~~~~~ ../drafter/ext/snowcrash/src/UriTemplateParser.cc:82:16: note: call 'std::move' explicitly to avoid copying return variableExpression; ^~~~~~~~~~~~~~~~~~ std::move(variableExpression)...
Nullable does not work for following use cases ``` apib # Data Structures # ArrayWithNullable (array) - m (nullable) # NullableString (string, nullable) ```
* over 1400 lines of code * ubiquitous repetitions * template hell
Default object with properties indented by 4 spaced from the `Default` denotation parse as the 'default' 'object' element (from https://raw.githubusercontent.com/apiaryio/mson-zoo/master/samples/0060-array-of-object-with-default.md) ```apib FORMAT: 1A # XYZ # Data Structures ## 0060-array-of-object-with-default...
This is really similiar to https://github.com/apiaryio/drafter/issues/350. Repro: ```drafter $ echo '# My Resource [realativePath]' | drafter element: "parseResult" content: - element: "category" meta: classes: element: "array" content: - element: "string"...
@klokane opened apiaryio/snowcrash#355 As say Blueprint specification: https://github.com/apiaryio/api-blueprint/blob/master/API%20Blueprint%20Specification.md#def-uriparameters-section ``` Members is the optional enumeration of possible values. should be surrounded by enum[] if this is present. For example, if enumeration...