Skip to content

Commit bf94d14

Browse files
committed
doc: Add a note on reducing ["prop value"] to a simple string
1 parent b908a47 commit bf94d14

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/lib.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,12 @@ pub struct Property {
144144
/// > The array element values MUST have the primitive type that matches the jCard type identifier. In RFC6350,
145145
/// > there are only structured text values and thus only JSON strings are used. For example, extensions may define
146146
/// > structured number or boolean values, where JSON number or boolean types MUST be used.
147+
/// >
148+
/// > ...
149+
/// >
150+
/// > Although it is allowed for a structured property value to hold just one component, it is RECOMMENDED to represent
151+
/// > it as a single text value instead, omitting the array completely. Nevertheless, a simple implementation MAY
152+
/// > choose to retain the array, with a single text value as its element.
147153
///
148154
/// ```rust
149155
/// # use vicardi::*;

0 commit comments

Comments
 (0)