@strictly/define 0.0.29 → 0.0.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.out/index.d.ts +26 -26
- package/.out/index.js +26 -26
- package/.out/transformers/copies/copy.d.ts +3 -3
- package/.out/transformers/copies/copy.js +1 -1
- package/.out/transformers/copies/{copy_to.d.ts → copyTo.d.ts} +3 -3
- package/.out/transformers/copies/{copy_to.js → copyTo.js} +1 -1
- package/.out/transformers/copies/mobxCopy.d.ts +5 -0
- package/.out/transformers/copies/{mobx_copy.js → mobxCopy.js} +3 -3
- package/.out/transformers/copies/specs/{copy_to.tests.js → copyTo.tests.js} +2 -2
- package/.out/transformers/copies/specs/{mobx_copy.tests.js → mobxCopy.tests.js} +1 -1
- package/.out/transformers/equals.d.ts +2 -2
- package/.out/transformers/equals.js +1 -1
- package/.out/transformers/flatteners/{flatten_accessors_of_type.d.ts → flattenAccessorsOfType.d.ts} +4 -4
- package/.out/transformers/flatteners/{flatten_accessors_of_type.js → flattenAccessorsOfType.js} +1 -1
- package/.out/transformers/flatteners/{flatten_json_value_to_type_paths_of.d.ts → flattenJsonValueToTypePathsOf.d.ts} +2 -2
- package/.out/transformers/flatteners/{flatten_json_value_to_type_paths_of.js → flattenJsonValueToTypePathsOf.js} +1 -1
- package/.out/transformers/flatteners/{flatten_type_to.d.ts → flattenTypeTo.d.ts} +1 -1
- package/.out/transformers/flatteners/{flatten_type_to.js → flattenTypeTo.js} +2 -2
- package/.out/transformers/flatteners/flattenTypesOfType.d.ts +3 -0
- package/.out/transformers/flatteners/{flatten_types_of_type.js → flattenTypesOfType.js} +1 -1
- package/.out/transformers/flatteners/{flatten_validation_errors_of_type.d.ts → flattenValidationErrorsOfType.d.ts} +5 -5
- package/.out/transformers/flatteners/{flatten_validation_errors_of_type.js → flattenValidationErrorsOfType.js} +1 -1
- package/.out/transformers/flatteners/{flatten_validators_of_validating_type.d.ts → flattenValidatorsOfValidatingType.d.ts} +3 -3
- package/.out/transformers/flatteners/{flatten_validators_of_validating_type.js → flattenValidatorsOfValidatingType.js} +1 -1
- package/.out/transformers/flatteners/{flatten_value_to.d.ts → flattenValueTo.d.ts} +4 -4
- package/.out/transformers/flatteners/{flatten_value_to.js → flattenValueTo.js} +2 -2
- package/.out/transformers/flatteners/{flatten_values_of_type.d.ts → flattenValuesOfType.d.ts} +2 -2
- package/.out/transformers/flatteners/{flatten_values_of_type.js → flattenValuesOfType.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_accessors_of_type.tests.js → flattenAccessorsOfType.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_json_value_to_type_paths_of.tests.js → flattenJsonValueToTypePathsOf.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_type_to.tests.js → flattenTypeTo.tests.js} +2 -2
- package/.out/transformers/flatteners/specs/{flatten_types_of_type.tests.js → flattenTypesOfType.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_validation_errors_of_type.tests.js → flattenValidationErrorsOfType.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_value_to.tests.js → flattenValueTo.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{flatten_values_of_type.tests.js → flattenValuesOfType.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{json_paths.tests.js → jsonPaths.tests.js} +1 -1
- package/.out/transformers/flatteners/specs/{value_path_to_type_path.tests.js → valuePathToTypePath.tests.js} +1 -1
- package/.out/transformers/flatteners/{value_path_to_type_path.d.ts → valuePathToTypePath.d.ts} +1 -1
- package/.out/transformers/flatteners/{value_path_to_type_path.js → valuePathToTypePath.js} +1 -1
- package/.out/tsconfig.tsbuildinfo +1 -1
- package/.out/types/{flattened_accessors_of_type.d.ts → FlattenedAccessorsOfType.d.ts} +2 -2
- package/.out/types/{flattened_types_of_type.d.ts → FlattenedTypesOfType.d.ts} +2 -2
- package/.out/types/{flattened_types_of_validating_type.d.ts → FlattenedTypesOfValidatingType.d.ts} +3 -3
- package/.out/types/{flattened_validators_of_validating_type.d.ts → FlattenedValidatorsOfValidatingType.d.ts} +4 -4
- package/.out/types/{flattened_values_of_type.d.ts → FlattenedValuesOfType.d.ts} +3 -3
- package/.out/types/{mobx_value_of_type.d.ts → MobxValueOfType.d.ts} +2 -2
- package/.out/types/{partial_type_of_type.d.ts → PartialTypeOfType.d.ts} +1 -1
- package/.out/types/{paths_of_type.d.ts → PathsOfType.d.ts} +2 -2
- package/.out/types/{readonly_type_of_type.d.ts → ReadonlyTypeOfType.d.ts} +1 -1
- package/.out/types/{strict_definitions.d.ts → StrictType.d.ts} +1 -1
- package/.out/types/{validating_definitions.d.ts → ValidatingType.d.ts} +1 -1
- package/.out/types/{validating_type_def_with_error.d.ts → ValidatingTypeDefWithError.d.ts} +2 -2
- package/.out/types/{value_of_type.d.ts → ValueOfType.d.ts} +1 -1
- package/.out/types/{value_to_type_paths_of_type.d.ts → ValueToTypePathsOfType.d.ts} +3 -3
- package/.out/types/{value_types_of_discriminated_union.d.ts → ValueTypesOfDiscriminatedUnion.d.ts} +3 -3
- package/.out/types/builders.d.ts +5 -5
- package/.out/types/builders.js +2 -2
- package/.out/types/flattened.d.ts +1 -1
- package/.out/types/specs/builder.tests.js +1 -1
- package/.out/types/{type_of_type.d.ts → typeOfType.d.ts} +1 -1
- package/.out/types/{type_of_type.js → typeOfType.js} +1 -1
- package/.out/validation/validator.js +1 -1
- package/.out/validation/validators/specs/{minimum_string_length_validator.tests.js → minimumStringLengthValidator.tests.js} +1 -1
- package/.out/validation/validators/specs/{regexp_validator.tests.js → regexpValidator.tests.js} +1 -1
- package/.turbo/turbo-build.log +6 -6
- package/.turbo/turbo-check-types.log +1 -1
- package/dist/index.cjs +22 -22
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +22 -22
- package/index.ts +26 -26
- package/package.json +1 -1
- package/transformers/copies/copy.ts +4 -4
- package/transformers/copies/{copy_to.ts → copyTo.ts} +9 -9
- package/transformers/copies/{mobx_copy.ts → mobxCopy.ts} +10 -10
- package/transformers/copies/specs/{copy_to.tests.ts → copyTo.tests.ts} +3 -3
- package/transformers/copies/specs/{mobx_copy.tests.ts → mobxCopy.tests.ts} +2 -2
- package/transformers/equals.ts +2 -2
- package/transformers/flatteners/{flatten_accessors_of_type.ts → flattenAccessorsOfType.ts} +7 -7
- package/transformers/flatteners/{flatten_json_value_to_type_paths_of.ts → flattenJsonValueToTypePathsOf.ts} +3 -3
- package/transformers/flatteners/{flatten_type_to.ts → flattenTypeTo.ts} +3 -5
- package/transformers/flatteners/{flatten_types_of_type.ts → flattenTypesOfType.ts} +3 -3
- package/transformers/flatteners/{flatten_validation_errors_of_type.ts → flattenValidationErrorsOfType.ts} +8 -8
- package/transformers/flatteners/{flatten_validators_of_validating_type.ts → flattenValidatorsOfValidatingType.ts} +4 -4
- package/transformers/flatteners/{flatten_value_to.ts → flattenValueTo.ts} +9 -9
- package/transformers/flatteners/{flatten_values_of_type.ts → flattenValuesOfType.ts} +4 -4
- package/transformers/flatteners/specs/{flatten_accessors_of_type.tests.ts → flattenAccessorsOfType.tests.ts} +3 -3
- package/transformers/flatteners/specs/{flatten_json_value_to_type_paths_of.tests.ts → flattenJsonValueToTypePathsOf.tests.ts} +1 -1
- package/transformers/flatteners/specs/{flatten_type_to.tests.ts → flattenTypeTo.tests.ts} +2 -2
- package/transformers/flatteners/specs/{flatten_types_of_type.tests.ts → flattenTypesOfType.tests.ts} +1 -1
- package/transformers/flatteners/specs/{flatten_validation_errors_of_type.tests.ts → flattenValidationErrorsOfType.tests.ts} +2 -2
- package/transformers/flatteners/specs/{flatten_value_to.tests.ts → flattenValueTo.tests.ts} +4 -4
- package/transformers/flatteners/specs/{flatten_values_of_type.tests.ts → flattenValuesOfType.tests.ts} +1 -1
- package/transformers/flatteners/specs/{json_paths.tests.ts → jsonPaths.tests.ts} +1 -1
- package/transformers/flatteners/specs/{value_path_to_type_path.tests.ts → valuePathToTypePath.tests.ts} +2 -2
- package/transformers/flatteners/{value_path_to_type_path.ts → valuePathToTypePath.ts} +1 -1
- package/types/{flattened_accessors_of_type.ts → FlattenedAccessorsOfType.ts} +2 -2
- package/types/{flattened_types_of_type.ts → FlattenedTypesOfType.ts} +6 -6
- package/types/{flattened_types_of_validating_type.ts → FlattenedTypesOfValidatingType.ts} +6 -6
- package/types/{flattened_validators_of_validating_type.ts → FlattenedValidatorsOfValidatingType.ts} +4 -4
- package/types/{flattened_values_of_type.ts → FlattenedValuesOfType.ts} +3 -3
- package/types/{mobx_value_of_type.ts → MobxValueOfType.ts} +2 -2
- package/types/{partial_type_of_type.ts → PartialTypeOfType.ts} +1 -1
- package/types/{paths_of_type.ts → PathsOfType.ts} +6 -6
- package/types/{readonly_type_of_type.ts → ReadonlyTypeOfType.ts} +1 -1
- package/types/{strict_definitions.ts → StrictType.ts} +1 -1
- package/types/{validating_definitions.ts → ValidatingType.ts} +1 -1
- package/types/{validating_type_def_with_error.ts → ValidatingTypeDefWithError.ts} +2 -2
- package/types/{value_of_type.ts → ValueOfType.ts} +1 -1
- package/types/{value_to_type_paths_of_type.ts → ValueToTypePathsOfType.ts} +7 -7
- package/types/{value_types_of_discriminated_union.ts → ValueTypesOfDiscriminatedUnion.ts} +3 -3
- package/types/builders.ts +5 -5
- package/types/flattened.ts +1 -1
- package/types/specs/{flattened_accessors_of_type.tests.ts → FlattenedAccessorsOfType.tests.ts} +1 -1
- package/types/specs/{flattened_types_of_type.tests.ts → FlattenedTypesOfType.tests.ts} +2 -2
- package/types/specs/{flattened_validators_of_validating_type.tests.ts → FlattenedValidatorsOfValidatingType.tests.ts} +2 -2
- package/types/specs/{flattened_values_of_type.tests.ts → FlattenedValuesOfType.tests.ts} +1 -1
- package/types/specs/{partial_type_of_type.tests.ts → PartialTypeOfType.tests.ts} +2 -2
- package/types/specs/{paths_of_type.tests.ts → PathsOfType.tests.ts} +1 -1
- package/types/specs/{readonly_type_of_type.tests.ts → ReadonlyTypeOfType.tests.ts} +2 -2
- package/types/specs/{strict_definitions.tests.ts → StrictType.tests.ts} +5 -5
- package/types/specs/{type_of_type.tests.ts → TypeOfType.tests.ts} +2 -2
- package/types/specs/{value_of_type.tests.ts → ValueOfType.tests.ts} +2 -2
- package/types/specs/{value_to_type_paths_of_type.tests.ts → ValueToTypePathsOfType.tests.ts} +2 -2
- package/types/specs/{value_types_of_discriminated_union.tests.ts → ValueTypesOfDiscriminatedUnion.tests.ts} +1 -1
- package/types/specs/builder.tests.ts +2 -2
- package/types/{type_of_type.ts → typeOfType.ts} +1 -1
- package/validation/specs/{errors_of_validators.tests.ts → errorsOfValidators.tests.ts} +1 -1
- package/validation/specs/{validators_of_values.tests.ts → validatorsOfValues.tests.ts} +1 -1
- package/validation/validator.ts +1 -1
- package/validation/validators/specs/{minimum_string_length_validator.tests.ts → minimumStringLengthValidator.tests.ts} +1 -1
- package/validation/validators/specs/{regexp_validator.tests.ts → regexpValidator.tests.ts} +1 -1
- package/.out/transformers/copies/mobx_copy.d.ts +0 -5
- package/.out/transformers/flatteners/flatten_types_of_type.d.ts +0 -3
- /package/.out/transformers/copies/specs/{copy_to.tests.d.ts → copyTo.tests.d.ts} +0 -0
- /package/.out/transformers/copies/specs/{mobx_copy.tests.d.ts → mobxCopy.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/{json_path.d.ts → jsonPath.d.ts} +0 -0
- /package/.out/transformers/flatteners/{json_path.js → jsonPath.js} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_accessors_of_type.tests.d.ts → flattenAccessorsOfType.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_json_value_to_type_paths_of.tests.d.ts → flattenJsonValueToTypePathsOf.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_type_to.tests.d.ts → flattenTypeTo.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_types_of_type.tests.d.ts → flattenTypesOfType.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_validation_errors_of_type.tests.d.ts → flattenValidationErrorsOfType.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_value_to.tests.d.ts → flattenValueTo.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{flatten_values_of_type.tests.d.ts → flattenValuesOfType.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{json_paths.tests.d.ts → jsonPaths.tests.d.ts} +0 -0
- /package/.out/transformers/flatteners/specs/{value_path_to_type_path.tests.d.ts → valuePathToTypePath.tests.d.ts} +0 -0
- /package/.out/types/{flattened_accessors_of_type.js → FlattenedAccessorsOfType.js} +0 -0
- /package/.out/types/{flattened_types_of_type.js → FlattenedTypesOfType.js} +0 -0
- /package/.out/types/{flattened_types_of_validating_type.js → FlattenedTypesOfValidatingType.js} +0 -0
- /package/.out/types/{flattened_validators_of_validating_type.js → FlattenedValidatorsOfValidatingType.js} +0 -0
- /package/.out/types/{flattened_values_of_type.js → FlattenedValuesOfType.js} +0 -0
- /package/.out/types/{mobx_value_of_type.js → MobxValueOfType.js} +0 -0
- /package/.out/types/{partial_type_of_type.js → PartialTypeOfType.js} +0 -0
- /package/.out/types/{path_of.d.ts → PathOf.d.ts} +0 -0
- /package/.out/types/{path_of.js → PathOf.js} +0 -0
- /package/.out/types/{paths_of_type.js → PathsOfType.js} +0 -0
- /package/.out/types/{readonly_type_of_type.js → ReadonlyTypeOfType.js} +0 -0
- /package/.out/types/{specs/flattened_accessors_of_type.tests.d.ts → StrictType.js} +0 -0
- /package/.out/types/{definitions.d.ts → Type.d.ts} +0 -0
- /package/.out/types/{definitions.js → Type.js} +0 -0
- /package/.out/types/{specs/flattened_types_of_type.tests.d.ts → ValidatingType.js} +0 -0
- /package/.out/types/{specs/flattened_validators_of_validating_type.tests.d.ts → ValidatingTypeDefWithError.js} +0 -0
- /package/.out/types/{specs/flattened_values_of_type.tests.d.ts → ValueOfType.js} +0 -0
- /package/.out/types/{specs/partial_type_of_type.tests.d.ts → ValueToTypePathsOfType.js} +0 -0
- /package/.out/types/{specs/paths_of_type.tests.d.ts → ValueTypesOfDiscriminatedUnion.js} +0 -0
- /package/.out/types/specs/{readonly_type_of_type.tests.d.ts → FlattenedAccessorsOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{flattened_accessors_of_type.tests.js → FlattenedAccessorsOfType.tests.js} +0 -0
- /package/.out/types/specs/{strict_definitions.tests.d.ts → FlattenedTypesOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{flattened_types_of_type.tests.js → FlattenedTypesOfType.tests.js} +0 -0
- /package/.out/types/specs/{type_of_type.tests.d.ts → FlattenedValidatorsOfValidatingType.tests.d.ts} +0 -0
- /package/.out/types/specs/{flattened_validators_of_validating_type.tests.js → FlattenedValidatorsOfValidatingType.tests.js} +0 -0
- /package/.out/types/specs/{value_of_type.tests.d.ts → FlattenedValuesOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{flattened_values_of_type.tests.js → FlattenedValuesOfType.tests.js} +0 -0
- /package/.out/types/specs/{value_to_type_paths_of_type.tests.d.ts → PartialTypeOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{partial_type_of_type.tests.js → PartialTypeOfType.tests.js} +0 -0
- /package/.out/types/specs/{value_types_of_discriminated_union.tests.d.ts → PathsOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{paths_of_type.tests.js → PathsOfType.tests.js} +0 -0
- /package/.out/types/{strict_definitions.js → specs/ReadonlyTypeOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{readonly_type_of_type.tests.js → ReadonlyTypeOfType.tests.js} +0 -0
- /package/.out/types/{validating_definitions.js → specs/StrictType.tests.d.ts} +0 -0
- /package/.out/types/specs/{strict_definitions.tests.js → StrictType.tests.js} +0 -0
- /package/.out/types/{validating_type_def_with_error.js → specs/TypeOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{type_of_type.tests.js → TypeOfType.tests.js} +0 -0
- /package/.out/types/{value_of_type.js → specs/ValueOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{value_of_type.tests.js → ValueOfType.tests.js} +0 -0
- /package/.out/types/{value_to_type_paths_of_type.js → specs/ValueToTypePathsOfType.tests.d.ts} +0 -0
- /package/.out/types/specs/{value_to_type_paths_of_type.tests.js → ValueToTypePathsOfType.tests.js} +0 -0
- /package/.out/types/{value_types_of_discriminated_union.js → specs/ValueTypesOfDiscriminatedUnion.tests.d.ts} +0 -0
- /package/.out/types/specs/{value_types_of_discriminated_union.tests.js → ValueTypesOfDiscriminatedUnion.tests.js} +0 -0
- /package/.out/validation/{errors_of_validators.d.ts → ErrorsOfValidators.d.ts} +0 -0
- /package/.out/validation/{errors_of_validators.js → ErrorsOfValidators.js} +0 -0
- /package/.out/validation/{validators_of_values.d.ts → ValidatorsOfValues.d.ts} +0 -0
- /package/.out/validation/{specs/errors_of_validators.tests.d.ts → ValidatorsOfValues.js} +0 -0
- /package/.out/validation/specs/{validators_of_values.tests.d.ts → errorsOfValidators.tests.d.ts} +0 -0
- /package/.out/validation/specs/{errors_of_validators.tests.js → errorsOfValidators.tests.js} +0 -0
- /package/.out/validation/{validators/specs/minimum_string_length_validator.tests.d.ts → specs/validatorsOfValues.tests.d.ts} +0 -0
- /package/.out/validation/specs/{validators_of_values.tests.js → validatorsOfValues.tests.js} +0 -0
- /package/.out/validation/validators/{composite_validator.d.ts → CompositeValidator.d.ts} +0 -0
- /package/.out/validation/validators/{composite_validator.js → CompositeValidator.js} +0 -0
- /package/.out/validation/validators/{defined_validator.d.ts → DefinedValidator.d.ts} +0 -0
- /package/.out/validation/validators/{defined_validator.js → DefinedValidator.js} +0 -0
- /package/.out/validation/validators/{maximum_string_length_validator.d.ts → MaximumStringLengthValidator.d.ts} +0 -0
- /package/.out/validation/validators/{maximum_string_length_validator.js → MaximumStringLengthValidator.js} +0 -0
- /package/.out/validation/validators/{minimum_string_length_validator.d.ts → MinimumStringLengthValidator.d.ts} +0 -0
- /package/.out/validation/validators/{minimum_string_length_validator.js → MinimumStringLengthValidator.js} +0 -0
- /package/.out/validation/validators/{optional_validator_proxy.d.ts → OptionalValidatorProxy.d.ts} +0 -0
- /package/.out/validation/validators/{optional_validator_proxy.js → OptionalValidatorProxy.js} +0 -0
- /package/.out/validation/validators/{regexp_validator.d.ts → RegexpValidator.d.ts} +0 -0
- /package/.out/validation/validators/{regexp_validator.js → RegexpValidator.js} +0 -0
- /package/.out/validation/validators/specs/{regexp_validator.tests.d.ts → minimumStringLengthValidator.tests.d.ts} +0 -0
- /package/.out/validation/{validators_of_values.js → validators/specs/regexpValidator.tests.d.ts} +0 -0
- /package/transformers/flatteners/{json_path.ts → jsonPath.ts} +0 -0
- /package/types/{path_of.ts → PathOf.ts} +0 -0
- /package/types/{definitions.ts → Type.ts} +0 -0
- /package/validation/{errors_of_validators.ts → ErrorsOfValidators.ts} +0 -0
- /package/validation/{validators_of_values.ts → ValidatorsOfValues.ts} +0 -0
- /package/validation/validators/{composite_validator.ts → CompositeValidator.ts} +0 -0
- /package/validation/validators/{defined_validator.ts → DefinedValidator.ts} +0 -0
- /package/validation/validators/{maximum_string_length_validator.ts → MaximumStringLengthValidator.ts} +0 -0
- /package/validation/validators/{minimum_string_length_validator.ts → MinimumStringLengthValidator.ts} +0 -0
- /package/validation/validators/{optional_validator_proxy.ts → OptionalValidatorProxy.ts} +0 -0
- /package/validation/validators/{regexp_validator.ts → RegexpValidator.ts} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { valuePathToTypePath } from 'transformers/flatteners/
|
|
1
|
+
import { valuePathToTypePath } from 'transformers/flatteners/valuePathToTypePath'
|
|
2
2
|
import {
|
|
3
3
|
booleanType,
|
|
4
4
|
list,
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
stringType,
|
|
9
9
|
union,
|
|
10
10
|
} from 'types/builders'
|
|
11
|
-
import { type ValueToTypePathsOfType } from 'types/
|
|
11
|
+
import { type ValueToTypePathsOfType } from 'types/ValueToTypePathsOfType'
|
|
12
12
|
|
|
13
13
|
describe('valuePathToTypePath', function () {
|
|
14
14
|
describe('literal', function () {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type
|
|
1
|
+
import { type FlattenedValuesOfType } from './FlattenedValuesOfType'
|
|
2
|
+
import { type Type } from './Type'
|
|
3
3
|
|
|
4
4
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
5
5
|
export type Accessor<T = any> = {
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
type UnionToIntersection,
|
|
3
3
|
} from 'type-fest'
|
|
4
|
+
import {
|
|
5
|
+
type Depths,
|
|
6
|
+
type StartingDepth,
|
|
7
|
+
} from './flattened'
|
|
8
|
+
import { type PathOf } from './PathOf'
|
|
4
9
|
import {
|
|
5
10
|
type ListTypeDef,
|
|
6
11
|
type LiteralTypeDef,
|
|
@@ -9,12 +14,7 @@ import {
|
|
|
9
14
|
type Type,
|
|
10
15
|
type TypeDef,
|
|
11
16
|
type UnionTypeDef,
|
|
12
|
-
} from './
|
|
13
|
-
import {
|
|
14
|
-
type Depths,
|
|
15
|
-
type StartingDepth,
|
|
16
|
-
} from './flattened'
|
|
17
|
-
import { type PathOf } from './path_of'
|
|
17
|
+
} from './Type'
|
|
18
18
|
|
|
19
19
|
// NOTE removing any ternary from this file improves the performance and the depth of data structure we can go to
|
|
20
20
|
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
type UnionToIntersection,
|
|
3
3
|
} from 'type-fest'
|
|
4
|
-
import {
|
|
5
|
-
type Type,
|
|
6
|
-
type TypeDef,
|
|
7
|
-
} from './definitions'
|
|
8
4
|
import {
|
|
9
5
|
type Depths,
|
|
10
6
|
type StartingDepth,
|
|
11
7
|
} from './flattened'
|
|
12
|
-
import { type PathOf } from './
|
|
8
|
+
import { type PathOf } from './PathOf'
|
|
9
|
+
import {
|
|
10
|
+
type Type,
|
|
11
|
+
type TypeDef,
|
|
12
|
+
} from './Type'
|
|
13
13
|
import {
|
|
14
14
|
type ContextOfValidatingTypeDef,
|
|
15
15
|
type ErrorOfValidatingTypeDef,
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
type ValidatingObjectTypeDef,
|
|
19
19
|
type ValidatingRecordTypeDef,
|
|
20
20
|
type ValidatingUnionTypeDef,
|
|
21
|
-
} from './
|
|
21
|
+
} from './ValidatingType'
|
|
22
22
|
|
|
23
23
|
// TODO rename to FlattenedValidatingTypesOfValidatingType
|
|
24
24
|
export type FlattenedTypesOfValidatingType<
|
package/types/{flattened_validators_of_validating_type.ts → FlattenedValidatorsOfValidatingType.ts}
RENAMED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { type Simplify } from 'type-fest'
|
|
2
2
|
import { type Validator } from 'validation/validator'
|
|
3
|
-
import { type FlattenedTypesOfType } from './
|
|
3
|
+
import { type FlattenedTypesOfType } from './FlattenedTypesOfType'
|
|
4
4
|
import {
|
|
5
5
|
type ReadonlyOfTypeDef,
|
|
6
|
-
} from './
|
|
6
|
+
} from './ReadonlyTypeOfType'
|
|
7
7
|
import {
|
|
8
8
|
type ErrorOfValidatingTypeDef,
|
|
9
9
|
type ValidatingType,
|
|
10
10
|
type ValidatingTypeDef,
|
|
11
|
-
} from './
|
|
11
|
+
} from './ValidatingType'
|
|
12
12
|
import {
|
|
13
13
|
type ValueOfTypeDef,
|
|
14
|
-
} from './
|
|
14
|
+
} from './ValueOfType'
|
|
15
15
|
|
|
16
16
|
type ValidatorOfValidatingType<T extends ValidatingTypeDef, ValuePath extends string> = T extends
|
|
17
17
|
ValidatingTypeDef<infer E, infer C> ? Validator<ValueOfTypeDef<ReadonlyOfTypeDef<T>>, E, ValuePath, C>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type
|
|
3
|
-
import { type ValueOfType } from './
|
|
1
|
+
import { type FlattenedTypesOfType } from './FlattenedTypesOfType'
|
|
2
|
+
import { type Type } from './Type'
|
|
3
|
+
import { type ValueOfType } from './ValueOfType'
|
|
4
4
|
|
|
5
5
|
export type FlattenedValuesOfType<
|
|
6
6
|
T extends Type,
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
import {
|
|
2
|
+
type Depths,
|
|
3
|
+
type StartingDepth,
|
|
4
|
+
} from './flattened'
|
|
5
|
+
import { type PathOf } from './PathOf'
|
|
1
6
|
import {
|
|
2
7
|
type ListTypeDef,
|
|
3
8
|
type LiteralTypeDef,
|
|
@@ -6,12 +11,7 @@ import {
|
|
|
6
11
|
type Type,
|
|
7
12
|
type TypeDef,
|
|
8
13
|
type UnionTypeDef,
|
|
9
|
-
} from './
|
|
10
|
-
import {
|
|
11
|
-
type Depths,
|
|
12
|
-
type StartingDepth,
|
|
13
|
-
} from './flattened'
|
|
14
|
-
import { type PathOf } from './path_of'
|
|
14
|
+
} from './Type'
|
|
15
15
|
|
|
16
16
|
export type PathsOfType<
|
|
17
17
|
T extends Type,
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
type RecordKeyType,
|
|
8
8
|
type TypeDefType,
|
|
9
9
|
type UnionKey,
|
|
10
|
-
} from './
|
|
10
|
+
} from './Type'
|
|
11
11
|
|
|
12
12
|
// TODO rename to something more descriptive (e.g. introspectable definitions, deterministic
|
|
13
13
|
// definitions, discriminated definitions). Maybe should just replace definitions since most
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type IsFieldReadonly } from '@strictly/base'
|
|
2
2
|
import {
|
|
3
3
|
type TypeDefType,
|
|
4
|
-
} from '
|
|
4
|
+
} from './Type'
|
|
5
5
|
import {
|
|
6
6
|
type Rule,
|
|
7
7
|
type ValidatingListTypeDef,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
type ValidatingRecordTypeDef,
|
|
11
11
|
type ValidatingTypeDef,
|
|
12
12
|
type ValidatingUnionTypeDef,
|
|
13
|
-
} from './
|
|
13
|
+
} from './ValidatingType'
|
|
14
14
|
|
|
15
15
|
// doesn't work, loses
|
|
16
16
|
// export type ValidatingTypeDefWithError2<T extends ValidatingTypeDef, E2> = T extends ValidatingTypeDef<infer E1>
|
|
@@ -2,6 +2,12 @@ import {
|
|
|
2
2
|
type SimplifyDeep,
|
|
3
3
|
type UnionToIntersection,
|
|
4
4
|
} from 'type-fest'
|
|
5
|
+
import {
|
|
6
|
+
type Depths,
|
|
7
|
+
type StartingDepth,
|
|
8
|
+
} from './flattened'
|
|
9
|
+
import { type PathOf } from './PathOf'
|
|
10
|
+
import { type StrictType } from './StrictType'
|
|
5
11
|
import {
|
|
6
12
|
type ListTypeDef,
|
|
7
13
|
type LiteralTypeDef,
|
|
@@ -9,13 +15,7 @@ import {
|
|
|
9
15
|
type RecordTypeDef,
|
|
10
16
|
type TypeDef,
|
|
11
17
|
type UnionTypeDef,
|
|
12
|
-
} from './
|
|
13
|
-
import {
|
|
14
|
-
type Depths,
|
|
15
|
-
type StartingDepth,
|
|
16
|
-
} from './flattened'
|
|
17
|
-
import { type PathOf } from './path_of'
|
|
18
|
-
import { type StrictType } from './strict_definitions'
|
|
18
|
+
} from './Type'
|
|
19
19
|
|
|
20
20
|
export type ValueToTypePathsOfType<
|
|
21
21
|
T extends StrictType,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type
|
|
3
|
-
import { type ValueOfType } from './
|
|
1
|
+
import { type ReadonlyTypeOfType } from './ReadonlyTypeOfType'
|
|
2
|
+
import { type UnionTypeDef } from './Type'
|
|
3
|
+
import { type ValueOfType } from './ValueOfType'
|
|
4
4
|
|
|
5
5
|
// gets a record of the values types for a discriminated union mapped according to
|
|
6
6
|
// their discriminators
|
package/types/builders.ts
CHANGED
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
type TypeDef,
|
|
15
15
|
TypeDefType,
|
|
16
16
|
type UnionKey,
|
|
17
|
-
} from './
|
|
17
|
+
} from './Type'
|
|
18
18
|
import {
|
|
19
19
|
type TypeOfType,
|
|
20
20
|
typeOfType,
|
|
21
|
-
} from './
|
|
21
|
+
} from './typeOfType'
|
|
22
22
|
import {
|
|
23
23
|
type Rule,
|
|
24
24
|
type ValidatingListTypeDef,
|
|
@@ -28,12 +28,12 @@ import {
|
|
|
28
28
|
type ValidatingType,
|
|
29
29
|
type ValidatingTypeDef,
|
|
30
30
|
type ValidatingUnionTypeDef,
|
|
31
|
-
} from './
|
|
32
|
-
import { type ValidatingTypeDefWithError } from './
|
|
31
|
+
} from './ValidatingType'
|
|
32
|
+
import { type ValidatingTypeDefWithError } from './ValidatingTypeDefWithError'
|
|
33
33
|
import {
|
|
34
34
|
type ValueOfType,
|
|
35
35
|
type ValueOfTypeDef,
|
|
36
|
-
} from './
|
|
36
|
+
} from './ValueOfType'
|
|
37
37
|
|
|
38
38
|
function emptyRule() {
|
|
39
39
|
return null
|
package/types/flattened.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Unfortunately the TS compiler will infinitely loop if we don't give it a way of breaking out.
|
|
2
2
|
// A starting depth of 10 (the maximum) will cause performance issues while developing
|
|
3
|
-
export type StartingDepth =
|
|
3
|
+
export type StartingDepth = 7
|
|
4
4
|
// Going much above a depth of 10 will also blow up
|
|
5
5
|
export type Depths = [-1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
|
package/types/specs/{flattened_accessors_of_type.tests.ts → FlattenedAccessorsOfType.tests.ts}
RENAMED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
numberType,
|
|
3
3
|
record,
|
|
4
4
|
} from 'types/builders'
|
|
5
|
-
import { type FlattenedAccessorsOfType } from 'types/
|
|
5
|
+
import { type FlattenedAccessorsOfType } from 'types/FlattenedAccessorsOfType'
|
|
6
6
|
|
|
7
7
|
describe('FlattenedAccessorsOfType', function () {
|
|
8
8
|
// note we only test a small example since most of the work is done in flatten
|
|
@@ -8,8 +8,8 @@ import {
|
|
|
8
8
|
stringType,
|
|
9
9
|
union,
|
|
10
10
|
} from 'types/builders'
|
|
11
|
-
import { type
|
|
12
|
-
import { type
|
|
11
|
+
import { type FlattenedTypesOfType } from 'types/FlattenedTypesOfType'
|
|
12
|
+
import { type TypeDefType } from 'types/Type'
|
|
13
13
|
|
|
14
14
|
describe('FlattenedTypesOfType', function () {
|
|
15
15
|
describe('literal', function () {
|
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
list,
|
|
4
4
|
numberType,
|
|
5
5
|
} from 'types/builders'
|
|
6
|
-
import { type FlattenedValidatorsOfValidatingType } from 'types/
|
|
7
|
-
import { type ValueToTypePathsOfType } from 'types/
|
|
6
|
+
import { type FlattenedValidatorsOfValidatingType } from 'types/FlattenedValidatorsOfValidatingType'
|
|
7
|
+
import { type ValueToTypePathsOfType } from 'types/ValueToTypePathsOfType'
|
|
8
8
|
import { type Validator } from 'validation/validator'
|
|
9
9
|
|
|
10
10
|
describe('FlattenedValidatorsOfValidatingType', function () {
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
record,
|
|
5
5
|
stringType,
|
|
6
6
|
} from 'types/builders'
|
|
7
|
-
import { type FlattenedValuesOfType } from 'types/
|
|
7
|
+
import { type FlattenedValuesOfType } from 'types/FlattenedValuesOfType'
|
|
8
8
|
|
|
9
9
|
describe('FlattenedValuesOfType', function () {
|
|
10
10
|
// note we only test a small example since most of the work is done in flatten
|
|
@@ -7,8 +7,8 @@ import {
|
|
|
7
7
|
stringType,
|
|
8
8
|
union,
|
|
9
9
|
} from 'types/builders'
|
|
10
|
-
import { type
|
|
11
|
-
import { type
|
|
10
|
+
import { type PartialTypeOfType } from 'types/PartialTypeOfType'
|
|
11
|
+
import { type TypeDefType } from 'types/Type'
|
|
12
12
|
|
|
13
13
|
describe('PartialTypeDefOf', function () {
|
|
14
14
|
describe('literal', function () {
|
|
@@ -6,8 +6,8 @@ import {
|
|
|
6
6
|
stringType,
|
|
7
7
|
union,
|
|
8
8
|
} from 'types/builders'
|
|
9
|
-
import { type
|
|
10
|
-
import { type
|
|
9
|
+
import { type ReadonlyTypeOfType } from 'types/ReadonlyTypeOfType'
|
|
10
|
+
import { type TypeDefType } from 'types/Type'
|
|
11
11
|
|
|
12
12
|
describe('ReadonlyTypeDefOf', function () {
|
|
13
13
|
describe('literal', function () {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
type TypeDefType,
|
|
3
|
-
type UnionTypeDef,
|
|
4
|
-
} from 'types/definitions'
|
|
5
1
|
import {
|
|
6
2
|
type IsStrictUnion,
|
|
7
3
|
type StrictUnionTypeDef,
|
|
8
|
-
} from 'types/
|
|
4
|
+
} from 'types/StrictType'
|
|
5
|
+
import {
|
|
6
|
+
type TypeDefType,
|
|
7
|
+
type UnionTypeDef,
|
|
8
|
+
} from 'types/Type'
|
|
9
9
|
|
|
10
10
|
describe('Strict Definitions', function () {
|
|
11
11
|
describe('IsStrictUnion', function () {
|
|
@@ -2,8 +2,8 @@ import {
|
|
|
2
2
|
list,
|
|
3
3
|
numberType,
|
|
4
4
|
} from 'types/builders'
|
|
5
|
-
import { type TypeDefType } from 'types/
|
|
6
|
-
import { type TypeOfType } from 'types/
|
|
5
|
+
import { type TypeDefType } from 'types/Type'
|
|
6
|
+
import { type TypeOfType } from 'types/typeOfType'
|
|
7
7
|
|
|
8
8
|
describe('TypeOfType', function () {
|
|
9
9
|
describe('literal', function () {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type SimplifyDeep } from 'type-fest'
|
|
2
2
|
import {
|
|
3
3
|
type TypeDefType,
|
|
4
|
-
} from 'types/
|
|
5
|
-
import { type ValueOfType } from 'types/
|
|
4
|
+
} from 'types/Type'
|
|
5
|
+
import { type ValueOfType } from 'types/ValueOfType'
|
|
6
6
|
|
|
7
7
|
describe('ValueOfType', function () {
|
|
8
8
|
describe('literal', function () {
|
package/types/specs/{value_to_type_paths_of_type.tests.ts → ValueToTypePathsOfType.tests.ts}
RENAMED
|
@@ -12,8 +12,8 @@ import {
|
|
|
12
12
|
stringType,
|
|
13
13
|
union,
|
|
14
14
|
} from 'types/builders'
|
|
15
|
-
import { type FlattenedTypesOfType } from 'types/
|
|
16
|
-
import { type ValueToTypePathsOfType } from 'types/
|
|
15
|
+
import { type FlattenedTypesOfType } from 'types/FlattenedTypesOfType'
|
|
16
|
+
import { type ValueToTypePathsOfType } from 'types/ValueToTypePathsOfType'
|
|
17
17
|
|
|
18
18
|
describe('ValueToTypePathsOfType', function () {
|
|
19
19
|
describe('literal', function () {
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
object,
|
|
6
6
|
union,
|
|
7
7
|
} from 'types/builders'
|
|
8
|
-
import { type ValueTypesOfDiscriminatedUnion } from 'types/
|
|
8
|
+
import { type ValueTypesOfDiscriminatedUnion } from 'types/ValueTypesOfDiscriminatedUnion'
|
|
9
9
|
|
|
10
10
|
describe('ValueTypesOfDiscriminatedUnion', function () {
|
|
11
11
|
it('matches expected type', function () {
|
|
@@ -10,8 +10,8 @@ import {
|
|
|
10
10
|
} from 'types/builders'
|
|
11
11
|
import {
|
|
12
12
|
TypeDefType,
|
|
13
|
-
} from 'types/
|
|
14
|
-
import { type Rule } from 'types/
|
|
13
|
+
} from 'types/Type'
|
|
14
|
+
import { type Rule } from 'types/ValidatingType'
|
|
15
15
|
|
|
16
16
|
describe('builder', function () {
|
|
17
17
|
describe('literal', function () {
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
type TypeDef,
|
|
14
14
|
TypeDefType,
|
|
15
15
|
type UnionTypeDef,
|
|
16
|
-
} from '
|
|
16
|
+
} from './Type'
|
|
17
17
|
|
|
18
18
|
// useful for turning annotated type to type (e.g. Removing validation from ValidatingDefinition)
|
|
19
19
|
export type TypeOfType<T extends Type> = T extends Type<infer D> ? {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Validator } from 'validation/validator'
|
|
2
|
-
import { type ValidatorsOfValues } from 'validation/
|
|
2
|
+
import { type ValidatorsOfValues } from 'validation/ValidatorsOfValues'
|
|
3
3
|
|
|
4
4
|
describe('FlattenedValidatorsOfType', function () {
|
|
5
5
|
describe('literal', function () {
|
package/validation/validator.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
MinimumStringLengthValidationErrorType,
|
|
3
3
|
MinimumStringLengthValidator,
|
|
4
|
-
} from 'validation/validators/
|
|
4
|
+
} from 'validation/validators/MinimumStringLengthValidator'
|
|
5
5
|
|
|
6
6
|
describe('MinimumStringLengthValidator', () => {
|
|
7
7
|
describe('required', () => {
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { type MobxValueOfType } from 'types/mobx_value_of_type';
|
|
2
|
-
import { type ReadonlyTypeOfType } from 'types/readonly_type_of_type';
|
|
3
|
-
import { type StrictType } from 'types/strict_definitions';
|
|
4
|
-
import { type ValueOfType } from 'types/value_of_type';
|
|
5
|
-
export declare function mobxCopy<T extends StrictType>(t: T, proto: ValueOfType<ReadonlyTypeOfType<T>>): MobxValueOfType<T>;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/.out/transformers/flatteners/specs/{flatten_type_to.tests.d.ts → flattenTypeTo.tests.d.ts}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/.out/types/{flattened_types_of_validating_type.js → FlattenedTypesOfValidatingType.js}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/.out/types/specs/{readonly_type_of_type.tests.d.ts → FlattenedAccessorsOfType.tests.d.ts}
RENAMED
|
File without changes
|
/package/.out/types/specs/{flattened_accessors_of_type.tests.js → FlattenedAccessorsOfType.tests.js}
RENAMED
|
File without changes
|