Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update readme for release on deno.land #129

Draft
wants to merge 317 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
317 commits
Select commit Hold shift + click to select a range
d8bdc6e
add some string types
DetachHead Feb 24, 2021
65f4690
3.2.0
DetachHead Feb 24, 2021
4fc289c
use bigint instead of number for IP type to prevent additional dots
DetachHead Feb 24, 2021
f3efc0c
add prettier required plugin
DetachHead Feb 25, 2021
33c92a8
better generic names for the TupleOf types
DetachHead Feb 25, 2021
645da17
FileName type
DetachHead Mar 3, 2021
7dbdaa7
3.3.0
DetachHead Mar 3, 2021
838a9c1
add replaceOne function & type and make replaceAll use ts-toolbelt-s …
DetachHead Mar 4, 2021
5bcdde7
3.4.0
DetachHead Mar 4, 2021
6dfbfb2
remove function from example code
DetachHead Mar 5, 2021
bf8abb0
add explanation/linter suppression for arrayOfAll type wrapper function
DetachHead Mar 5, 2021
e651ee9
add a TODO
DetachHead Mar 5, 2021
0035074
add exactly "type"
DetachHead Mar 5, 2021
d2f8c46
ignore dist folder in idea
DetachHead Mar 8, 2021
0095891
better method for TupleOfExcluding that doesn't confuse the compiler
DetachHead Mar 8, 2021
c3270ef
don't use any, any is cringe
DetachHead Mar 8, 2021
50856e1
rename FirstChar to Head and add Tail type
DetachHead Mar 8, 2021
66d83a6
add LengthGreaterOrEqual, LengthGreaterThan and CaseInsensitive strin…
DetachHead Mar 8, 2021
0e04079
4.0.0
DetachHead Mar 8, 2021
f749c9e
make Multiply type distributive (i think thats the right word)
DetachHead Mar 10, 2021
ea6b663
add & subtract tests for distributive unions
DetachHead Mar 14, 2021
3235aab
rename the generics in the Divide helper types so that it's actually …
DetachHead Mar 14, 2021
44fdce3
make Divide distributive
DetachHead Mar 14, 2021
abe9696
shrinkwrap
DetachHead Mar 21, 2021
fd7dc02
add Index array type
DetachHead Mar 23, 2021
2306ec1
remove main files due to conflicting symbol names and only publish di…
DetachHead Mar 23, 2021
5134bef
indexOf array type & function
DetachHead Mar 23, 2021
6ad1688
fix string Join type using new Narrow type from ts-toolbelt
DetachHead Mar 23, 2021
2515425
add power-assert types
DetachHead Mar 23, 2021
d6bddc0
update shrinkwrap
DetachHead Mar 23, 2021
4c5ef9b
5.0.0
DetachHead Mar 23, 2021
afb164e
fix wording
DetachHead Mar 23, 2021
3407bcf
add flat function that uses Flatten util type from ts-toolbelt
DetachHead Mar 24, 2021
1a7da2d
use Narrow type on concat function so you dont need to use "as const"…
DetachHead Mar 24, 2021
a9f786e
suppress BadExpressionStatementJS in a test
DetachHead Mar 24, 2021
297426c
add FlattenedTupleOf
DetachHead Mar 24, 2021
ec7698d
reformat to minimize the amount of code suppressed by @ts-expect-error
DetachHead Mar 24, 2021
061aa92
6.0.0
DetachHead Mar 24, 2021
3076e25
update exactly documentation to mention it can be useful when testing…
DetachHead Mar 28, 2021
f59908f
add PadStart type & function
DetachHead Mar 28, 2021
68808bf
remove redundant N extends 1 check from DuplicateString
DetachHead Mar 28, 2021
3eb39a9
use spaced-comment eslint rule to fix / prevent broken ExpectType com…
DetachHead Mar 28, 2021
c9d5f09
6.1.0
DetachHead Mar 28, 2021
d6c8880
TemplateLiteralStringable type
DetachHead Mar 29, 2021
61a819e
fix copy/pasted examples
DetachHead Mar 29, 2021
e6f61e8
add leadingZeros function
DetachHead Mar 29, 2021
4deccb1
fix PadStart with template literal types like `000${number}`
DetachHead Mar 29, 2021
d7cdf35
6.2.0
DetachHead Mar 29, 2021
c101909
update to ts 4.3, and remove ts-expect-error's for issues fixed in 4.3
DetachHead Apr 6, 2021
fdbb6b1
reduce numbers for subtract big numbers test due to https://github.co…
DetachHead Apr 6, 2021
532bf13
make eslint run prettier
DetachHead Apr 6, 2021
355ce39
make typescript a dev dependency so the helper functions can be used …
DetachHead Apr 6, 2021
3979783
6.3.0
DetachHead Apr 6, 2021
3933199
remove COMMENT_MARKER from todo checker since it's not needed anymore
DetachHead Apr 6, 2021
bb4108d
add new flags
DetachHead Apr 6, 2021
931c6a5
add vcs file to prevent intellij from disabling git integration
DetachHead Apr 6, 2021
570c868
fix wrong example
DetachHead Apr 13, 2021
efdb860
remove empty comment
DetachHead Apr 13, 2021
a9f5e1c
split expressions with @ts-expect-error comments into seperate lines …
DetachHead Apr 13, 2021
5bcd3ff
add startswith and endswith types/functions
DetachHead Apr 13, 2021
037e110
Keys type
DetachHead Apr 13, 2021
c4d0db5
make leadingZeros work with negatives and improve types when the valu…
DetachHead Apr 13, 2021
3ba74ac
better Replace type
DetachHead Apr 13, 2021
36a2ce6
ReplaceValuesWithMap, EnumerateAsString and RangeAsString types
DetachHead Apr 13, 2021
87beafa
make PadStart distributive
DetachHead Apr 13, 2021
0cd4b7a
unfinished and terribly broken formatted date parser type thing
DetachHead Apr 13, 2021
8da579b
fix leadingZeros with negative numbers
DetachHead Apr 13, 2021
a251039
add isGreaterThan function & type
DetachHead Apr 15, 2021
a4a0357
LengthGreaterThan for arrays
DetachHead Apr 15, 2021
ddb051c
TupleOfAtLeast type maybe idk i'm tired
DetachHead Apr 16, 2021
094ed1f
fix wrong test
DetachHead Apr 18, 2021
40d36ce
fix IsGreaterThan incorrectly returning true when the values are equal
DetachHead Apr 18, 2021
78cbfcc
add a bunch of types (and some functions to match) mainly in preparat…
DetachHead Apr 18, 2021
e63f988
SortLongestStrings type and function
DetachHead Apr 18, 2021
4b58718
doc for Splice
DetachHead Apr 18, 2021
a234685
fix splice test
DetachHead Apr 18, 2021
b9eeac4
suppress intellij warnings
DetachHead Apr 18, 2021
b34999a
fix busted tetss/functions
DetachHead Apr 19, 2021
01e05ae
add documentation to splice
DetachHead Apr 19, 2021
8149020
LongestString type and fix RangeAsString using a number
DetachHead Apr 19, 2021
c2ef5ee
use TemplateLiteralStringable for ReplaceOne
DetachHead Apr 19, 2021
0c9ee90
MatchStart type
DetachHead Apr 19, 2021
4cb16b8
HighestNumber type and function
DetachHead Apr 19, 2021
7bc2c4e
make Ordinal default to number
DetachHead Apr 19, 2021
e15ead3
finished date format type
DetachHead Apr 19, 2021
0c9faf2
6.4.0
DetachHead Apr 19, 2021
c764f8c
update readme with date stuff
DetachHead Apr 19, 2021
c9487bf
formatting
DetachHead Apr 19, 2021
ebdc802
add a documemntation
DetachHead Apr 24, 2021
a729c96
change from tabs to spaces
DetachHead Apr 20, 2021
dbef0dc
run prettier seperately to eslint cuz eslint plugin is janky
DetachHead Apr 20, 2021
a807b98
run prettier on jsons and yaml's as well
DetachHead Apr 20, 2021
82d2c10
run prettier fix
DetachHead Apr 20, 2021
ed9078a
remove conflicting eslint rule
DetachHead Apr 20, 2021
4493482
move the map replacing logic to for FormattedDate to ReplaceValuesWit…
DetachHead Apr 20, 2021
15c3864
add EvaluateType type
DetachHead Apr 24, 2021
77d8209
add entries type & function, rename Object file to Any because it tec…
DetachHead Apr 24, 2021
75f40c3
format:fix
DetachHead Apr 24, 2021
4cef2ab
7.0.0
DetachHead Apr 24, 2021
d5fefed
enforce trailing commas
DetachHead Apr 24, 2021
6b8ae88
prettierignore package.json and package-lock.json because npm changes…
DetachHead Apr 24, 2021
641e8a4
update intellij formatter config to match new pretteir rules
DetachHead Apr 24, 2021
bb0d29d
remove eslint prettier plugin, pretty sure the config is all we need
DetachHead Apr 24, 2021
2af41a0
add mapNotUndefined function and RemoveValue type
DetachHead Apr 28, 2021
874a253
fix wrong type name in doc block
DetachHead May 29, 2021
3107464
add VSC settings.json to use the correct project version of typescript.
snipIts May 29, 2021
1201df5
fix doc
DetachHead May 31, 2021
c337a59
prettier fix
DetachHead May 31, 2021
5a66bbe
canary publish
DetachHead Apr 28, 2021
a2860b5
add SplitByUnion type
DetachHead May 31, 2021
db1bf65
fuckin ExpectType and its string-based comparisons
DetachHead May 31, 2021
8be7b52
add SplitByLength type
DetachHead May 31, 2021
90d92fa
add NumberToBinary type
DetachHead May 31, 2021
cd92f1f
add slice type & function
DetachHead Jun 6, 2021
b284586
add power and square
DetachHead Jun 9, 2021
3c275cc
fix Multiply with number type
DetachHead Jun 9, 2021
d530878
fix NumberToBinary with number type and add tests
DetachHead Jun 13, 2021
aee3f2d
BinaryToNumber type
DetachHead Jun 13, 2021
9f4287d
add leftshift and rightshift
DetachHead Jun 16, 2021
994078f
fix divide with number type
DetachHead Jun 16, 2021
98d3a28
enable no-throw-literal rule
DetachHead Jul 3, 2021
fb98ed0
add failCI function
DetachHead Jul 3, 2021
2f90178
add misc.spec.ts and move stuff that was incorrectly in String.spec.ts
DetachHead Jul 3, 2021
13c0157
fix line separator config in intellij
DetachHead Jul 3, 2021
8132ccc
better output for isCI
DetachHead Jul 3, 2021
ad1e79a
add isErrnoException
DetachHead Jul 3, 2021
ad91605
publish source code w/ declarationMap
DetachHead Jul 3, 2021
acbe408
fix dev dependencies that were incorrectly martked as prod dependencies
DetachHead Jul 25, 2021
48fa648
2 width tabs???? what??????
DetachHead Jul 25, 2021
90392fe
add a bunch of eslint rules
DetachHead Jul 27, 2021
0fd71d6
fix Enumerate with non-literal numbers
DetachHead Jul 27, 2021
7801830
add epic forEach function
DetachHead Jul 27, 2021
4a7dfb5
8.0.0
DetachHead Jul 27, 2021
3916503
update ts to 4.4 beta
DetachHead Jul 27, 2021
c26cfa0
update ts to 4.4.0-dev.20210727 because it fixes whatever was causing…
DetachHead Jul 27, 2021
3e270fb
eslint fixes
DetachHead Jul 27, 2021
2ba6b76
prettier fixes
DetachHead Jul 27, 2021
5cf9950
make explicit-module-boundary-types an error
DetachHead Jul 27, 2021
91ad259
add test for when forEach array values/length isn't known at compiletime
DetachHead Jul 27, 2021
fd8a37f
upgrade/fix exactly function
Aug 1, 2021
ae75f62
fix and organise tests
DetachHead Aug 2, 2021
aa91602
formatting and fix type for exactly impl
DetachHead Aug 2, 2021
17a29ae
fix typo
DetachHead Aug 2, 2021
6b996ec
fix and restructure documentation for exactly/Equals
DetachHead Aug 2, 2021
7f98fca
deprecated testType in favor of exactly
DetachHead Aug 2, 2021
701337d
ban any
DetachHead Aug 2, 2021
76841ff
specify return type for arrayOfAll
DetachHead Aug 2, 2021
786f377
add Not and Or types
DetachHead Aug 2, 2021
077aa1e
add missing comparison types & functions
DetachHead Aug 2, 2021
4d800ee
disable allowUnreachableCode
DetachHead Aug 2, 2021
39ea3ae
add concatenate function
DetachHead Aug 2, 2021
06ea5fd
add OptionalParameterFromGeneric type
DetachHead Aug 2, 2021
809a17e
add truncate function and type
DetachHead Aug 2, 2021
204edbe
use overloads for truncate function because OptionalParameterFromGene…
DetachHead Aug 2, 2021
9dca249
fix incorrect tests
DetachHead Aug 2, 2021
9d43de9
add documentation for truncate function
DetachHead Aug 2, 2021
f58d83f
rename oneOrTwo since it's a union not an intersection
DetachHead Aug 2, 2021
b9a4617
remove useless variable
DetachHead Aug 2, 2021
3f36a5f
add a 3rd overload to exactly
DetachHead Aug 2, 2021
e8ef1de
formatting
DetachHead Aug 2, 2021
9ca47d0
add truncate test to make sure it works when the value isn't known at…
DetachHead Aug 2, 2021
103bf39
fix returning values to jest functions
DetachHead Aug 2, 2021
15cceec
lock the typescript version
DetachHead Aug 2, 2021
f5da685
github releases
DetachHead Aug 2, 2021
9496ec3
8.1.0
DetachHead Aug 3, 2021
bdafadd
make Slice less gross
DetachHead Aug 3, 2021
e0a7b87
fix wrong example for exactly's "value" overload
DetachHead Aug 3, 2021
50f6021
enable stripInternal
DetachHead Aug 3, 2021
d904083
don't publish/release if version hasn't changed
DetachHead Aug 3, 2021
ea95508
don't download artifacts if it doesn't need to publish
DetachHead Aug 3, 2021
00aecd5
8.1.1
DetachHead Aug 3, 2021
f66b993
does npm shrinkwrap force it to always download dev dependencies?????…
DetachHead Aug 3, 2021
70b65ab
lock versions now that shrinkwrap can't be used
DetachHead Aug 3, 2021
3f81536
fix ts-is-present incorrectly marked as a dev dependency
DetachHead Aug 3, 2021
f625abb
update package-lock
DetachHead Aug 3, 2021
2aea84e
8.1.2
DetachHead Aug 3, 2021
e362540
enable isolatedModules so modules can't accidentally be global
DetachHead Aug 8, 2021
486ad22
mark src folder
DetachHead Aug 8, 2021
dccb5dc
add OnlyInfer type
DetachHead Aug 7, 2021
eb3c8c7
use OnlyInfer for exactly function
DetachHead Aug 8, 2021
bf11140
fix doc formatting
DetachHead Aug 9, 2021
f554824
split findNotUndefined into async and sync version, return object ins…
DetachHead Aug 31, 2021
f318875
fix issue where hasPropertyPredicate was inferring a type where the v…
DetachHead Sep 28, 2021
5562b8b
add todo type and function
DetachHead Sep 29, 2021
1ac78cb
fix import fails
DetachHead Sep 29, 2021
b491b33
add castArray function & type
DetachHead Sep 30, 2021
2081782
fix mistake in exactly documentation
DetachHead Sep 30, 2021
8d7ffc8
formatting fix
DetachHead Sep 30, 2021
260e41e
fix type testing for intersections
DetachHead Sep 30, 2021
4531c2a
8.2.0
DetachHead Sep 30, 2021
522643d
add ipv4/ipv6 types & repurpose assertType function since there's sti…
DetachHead Oct 1, 2021
0c63e3c
add Integer, PositiveNumber and NegativeNumber types
DetachHead Oct 10, 2021
4bc8393
add makeStartsWith and makeEndsWith
DetachHead Oct 11, 2021
30d5f1e
add epicsauce map function
DetachHead Oct 12, 2021
01db705
fix EvaluateType & add EvaluateTypeRecursively
DetachHead Oct 4, 2021
2cd4b49
rewrite EvaluateType to take an optional depth parameter
DetachHead Oct 4, 2021
1c845a9
update to ts 4.5 and rewrite some types to be tail recursive
DetachHead Oct 4, 2021
78cf963
add Extends type
DetachHead Oct 4, 2021
40b05a0
add issue link to Add documentation
DetachHead Oct 4, 2021
6fedf11
fix tests in wrong file
DetachHead Oct 4, 2021
2ace54f
make DuplicateString tail recursive
DetachHead Oct 4, 2021
84b10f4
rewrite IP types using Join & TupleOf
DetachHead Oct 4, 2021
60d715a
add based vscode config
DetachHead Oct 4, 2021
2891064
formatting
DetachHead Oct 4, 2021
3ef53a6
update hasPropertyPredicate documentation
DetachHead Oct 4, 2021
9ea4a40
fix return type for exactly value overload
DetachHead Oct 4, 2021
ef8b3f3
rewrite IndexOf to be tail recursive
DetachHead Oct 4, 2021
c9b9ec6
rewrite indexOf tests & add stack depth test
DetachHead Oct 4, 2021
ecd76fe
fix indexof stack depth test
DetachHead Oct 4, 2021
810681a
remove EvaluateType because it doesnt work properly and ts-toolbelt h…
DetachHead Oct 10, 2021
776fd00
fix TupleOfUpTo. the type it created was completely wrong andthere's …
DetachHead Oct 10, 2021
45c7ae5
update documentation for Any/Keys to explain the difference between t…
DetachHead Oct 10, 2021
2f17aa7
rewrite SortLongestStrings to be tail-recursive
DetachHead Oct 11, 2021
73c9981
rewrite RemoveValue to be tail-recursive and add tests
DetachHead Oct 11, 2021
32f45b3
fix describe returning a value
DetachHead Oct 12, 2021
f509bbe
remove a bunch of ts-expect-error's by using intersections
DetachHead Oct 12, 2021
02813e8
remove outdated todo
DetachHead Oct 12, 2021
d1ffc13
rewrite Power to be tail recursive
DetachHead Oct 12, 2021
8d89a28
rewrite some nmber types to be tail recursive, remove binary types be…
DetachHead Oct 12, 2021
ab36e13
remove any that shouldn't have been there
DetachHead Oct 12, 2021
c3c502f
remove some more ts-expect-errors, using conditional types
DetachHead Oct 12, 2021
46d6c07
rewrite CaseInsensitive to be tail-recursive
DetachHead Oct 12, 2021
46444c6
rewrite CaseInsensitive to be tail-recursive
DetachHead Oct 12, 2021
e99e019
add requirements section
DetachHead Oct 12, 2021
8cf66f7
add back import i accidentally deleted
DetachHead Oct 12, 2021
1af80f7
add deno support
DetachHead Oct 12, 2021
8607abb
add check for invalid d.ts files as a result of stripped ignore comments
DetachHead Oct 13, 2021
c32bf81
add not literal test for IndexOf
DetachHead Oct 14, 2021
8a3bbed
update package-lock.json
DetachHead Oct 14, 2021
633a27a
add leftOf, rightOf, midOf and countInString
DetachHead Oct 14, 2021
b7041dd
add missing documentation
DetachHead Oct 14, 2021
2b5da5d
remove export for internal type that shouldn't be exposed
DetachHead Oct 14, 2021
9db4674
update project as per industry standards
DetachHead Oct 14, 2021
ee63ad5
update ts since they fixed stack depth issues, removed workarounds
DetachHead Oct 14, 2021
1157e30
update ts since they fixed stack depth issues, removed workarounds
DetachHead Oct 14, 2021
98abc37
add uppercase/lowercase functions that use the compiler intrinsic types
DetachHead Oct 15, 2021
76aac1c
fix assert logic in exactly function
DetachHead Oct 15, 2021
d334571
add toNumber function
DetachHead Oct 15, 2021
75c06d7
fix ts-jest types
DetachHead Oct 16, 2021
5438e77
fix hasPropertyPredicate with undefined and null values
DetachHead Oct 17, 2021
92826fa
fix exactly incorrectly comparing undefined types
DetachHead Oct 17, 2021
d7d2d6a
add guid type
DetachHead Oct 18, 2021
fc68c2e
rewrite old tests to use exactly instead of ExpectType and assertType
DetachHead Oct 17, 2021
f275349
10.0.0
DetachHead Oct 18, 2021
376f95d
prevent tests from being published
DetachHead Oct 18, 2021
bc503a9
remove wrong comment
DetachHead Oct 18, 2021
460460a
fix narrowing on toStringType
DetachHead Oct 18, 2021
c94f5ce
add NoAny
DetachHead Oct 27, 2021
b0d3961
update readme for release on `deno.land`
DetachHead Nov 21, 2021
8bf569e
add placeholder readme for `deno.land`
DetachHead Nov 21, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix busted tetss/functions
  • Loading branch information
DetachHead committed Apr 19, 2021
commit b34999a9e487e40bd4dadfd0b6bdccc0e67beb98
5 changes: 3 additions & 2 deletions src/utilityFunctions/Array.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
} from '../utilityTypes/Array'
import { Narrow } from 'ts-toolbelt/out/Function/Narrow'
import { Flatten } from 'ts-toolbelt/out/List/Flatten'
import { orderBy } from 'lodash'

/**
* checks whether the given array's length is larger than **or equal to** the given number, and narrows the type of the
Expand Down Expand Up @@ -196,7 +197,7 @@ export function splice<
startIndex: StartIndex,
deleteCount: DeleteCount
): Splice<Array, StartIndex, DeleteCount> {
return array.splice(startIndex, deleteCount) as never
return array.filter((_, index) => index < startIndex || index > deleteCount + 1) as never
}

/**
Expand Down Expand Up @@ -235,5 +236,5 @@ export function indexOfLongestString<Strings extends string[]>(
export function sortByLongestStrings<Strings extends string[]>(
strings: Narrow<Strings>
): SortLongestStrings<Strings> {
return strings.sort((string) => string.length) as never
return orderBy(strings, 'length', 'desc') as never
}
2 changes: 1 addition & 1 deletion src/utilityFunctions/__tests__/Number.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ describe('comparison', () => {
describe('isGreaterThan', () => {
test('true', () => {
const value = isGreaterThan(5, 4) // $ExpectType true
assert(!value)
assert(value)
})
test('false', () => {
isGreaterThan(5, 20) // $ExpectType false
Expand Down