1

I added the ajv validation plugin through the standard way:

import { RxDBAjvValidatePlugin } from 'rxdb/plugins/ajv-validate';

addRxPlugin(RxDBAjvValidatePlugin);

and now see the following error:

Uncaught Error: strict mode: unknown keyword: "encrypted"

While my schema does not contain the encrypted keyword at all, it is allowable by RxDB. So, the ajv validation does not let this rule pass in strict mode.

However, it is possible to tinker around with ajv configuration and prevent the appearence of this error (for example, by setting ajv.addKeyword("encrypted")). The question is how to do it (provide the configuration to the plugin) using RxDB?

Ilya Loskutov
  • 1,967
  • 2
  • 20
  • 34

0 Answers0