Skip to content

lagoasoft-lucasschmidt/knockout-validations-error-handler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

knockout validations error handler

A small function that will grab given errors and insert into an observable that uses extender knockout-validations-extender.

Uses feature manualErrors from that extender.

Params

  • errors
    • array of error object (has path, has message). Eg: {"path": "consumer.id", message: "notNull"}
  • givenObservable
    • observable that extends knockout-validations-extender
  • [translateMessage]
    • function that receives a key, can return a translation of a message

Change log

  • 0.0.2 -- fixed when accessing array paths, eg: consumers[0].id

About

Small function to add manual errors to knockout-validations-extender.

Resources

Stars

Watchers

Forks

Packages

No packages published