There was an error while loading. Please reload this page.
1 parent a1ddb3a commit 5b8c283Copy full SHA for 5b8c283
README.md
@@ -1185,6 +1185,18 @@ directives (see [Modules](#modules)).
1185
some_value = [a: "baz", b: "qux"]
1186
```
1187
1188
+* <a name="map-key-atom"></a>
1189
+ Use the shorthand key-value syntax for maps when all of the keys are atoms.
1190
+ <sup>[[link](#map-key-atom)]</sup>
1191
+
1192
+ ```elixir
1193
+ # not preferred
1194
+ %{:a => 1, :b => 2, :c => 0}
1195
1196
+ # preferred
1197
+ %{a: 1, b: 2, c: 3}
1198
+ ```
1199
1200
### Strings
1201
1202
* <a name="strings-matching-with-concatenator"></a>
0 commit comments