0.1.0
We are delighted to introduce our new version of library. For more info click on GuardedStruct.
GuardedStruct
The creation of this macro will allow you to build Structs
that provide you with a number of important options, including the following:
- Validation
- Sanitizing
- Constructor
- It provides the capacity to operate in a nested style simultaneously.
Suppose you are going to collect a number of pieces of information from the user, and before doing anything else, you are going to sanitize them.
After that, you are going to validate each piece of data, and if there are no issues, you will either display it in a proper output or save it somewhere else.
All of the characteristics that are associated with this macro revolve around cleaning and validating the data.
The features that we list below are individually based on a particular strategy and requirement, but thankfully, they may be combined and mixed in any way that you see fit.
Some of the changes in this version:
Changelog for MishkaDeveloperTools 0.1.0
- Add Guardedstruct macro
- Support nested struct in macro
- Add
derive
for Validation and Sanitization - Add custom validator and main validator
- Add custom validator and main validator from finding in a module
- Add
__struct__
,keys
,enforce_keys
andbuilder
functions - Add
required_fields
validation with:halt
status - Add calling nested fields and struct from another module
- Add
Derive.Parser.convert_to_atom_map
to Change string map to atom map - Add
derive
for sanitizing and validatingTrim
- Add
derive
for sanitizing and validatingLowercase
- Add
derive
for sanitizing and validatingUppercase
- Add
derive
for sanitizing and validatingMax
length - Add
derive
for sanitizing and validatingMin
length - Add
derive
for sanitizing and validating Safe Stringfalse
ortrue
value - Add
derive
for sanitizing and validatingEmail
- Add
derive
for sanitizing and validatingLocation
- Add
derive
for sanitizing and validatingDate
- Add
derive
for sanitizing and validatingDateTime
- Add
derive
for sanitizing and validatingbasic_html
sanitize - Add
derive
for sanitizing and validatinghtml5
sanitize - Add
derive
for sanitizing and validatingmarkdown_html
sanitize - Add
derive
for sanitizing and validatingstrip_tags
sanitize - Add
derive
for sanitizing and validatingRegex
runner - Add
derive
for sanitizing and validatingRange
- Add
derive
for sanitizing and validating ValidateURL
- Add
derive
for sanitizing and validating ValidateIPV4
- Add
derive
for sanitizing and validating ValidateEnum
- Add
derive
for sanitizing and validating ValidateTag
- Add
derive
for sanitizing and validating ValidateUUID
- Add
derive
for sanitizing and validating ValidateNot empty string
- Add
derive
for sanitizing and validating ValidateEqual
- Add a
:halt
error to filter validations output from showing afterhalt
error - Update all dependencies to last version
- Fix tests for Elixir
1.15
- Make all dependencies optional based on user requirements
- improve documents
Special thanks to @pouriya and @samdvr
Full Changelog: 0.0.8...0.1.0