Skip to content

Commit 113e7ac

Browse files
authored
Format note on browser version limitations
1 parent 3d673f5 commit 113e7ac

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

docs/browser.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,9 @@ const doc = new mongoose.Document({}, new mongoose.Schema({
3434
}));
3535
// Prints an error because `name` is required.
3636
console.log(doc.validateSync());
37-
> **Note:** The browser version of Mongoose supports only schema-based
38-
> validation. Built-in validators (like `required`, `enum`, `minlength`) and
39-
> custom validators work as expected using `validate()` or `validateSync()`.
40-
> However, browser Mongoose does **not** support models, queries, defaults,
41-
> middleware (hooks), or any database operations. Only document validation
42-
> is available in the browser build.
4337
```
38+
39+
**Note:** The browser version of Mongoose supports only schema-based validation.
40+
Built-in validators (like `required`, `enum`, `minlength`) and custom validators work as expected using `validate()` or `validateSync()`.
41+
However, browser Mongoose does **not** support models, queries, defaults, middleware (hooks), or any database operations.
42+
Only document validation is available in the browser build.

0 commit comments

Comments
 (0)