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

feat: Upgrade to TypeScript 4 and remove deprecated API #118

Merged
merged 2 commits into from Sep 8, 2020
Merged

Conversation

diegohaz
Copy link
Owner

@diegohaz diegohaz commented Sep 8, 2020

Closes #109
Closes #117

BREAKING CHANGE: Types now depend on TypeScript v4.0.

BREAKING CHANGE: The deprecated function/object API has been removed.

Before:

import createUseContext from "constate";
const useCounterContext = createUseContext(useCounter);
<useCounterContext.Provider>
  ...
</useCounterContext.Provider>

After:

import constate from "constate";
const [CounterProvider, useCounterContext] = constate(useCounter);
<CounterProvider>
  ...
</CounterProvider>

@codecov-commenter
Copy link

codecov-commenter commented Sep 8, 2020

Codecov Report

Merging #118 into master will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #118   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines           54        29   -25     
  Branches         7         4    -3     
=========================================
- Hits            54        29   -25     
Impacted Files Coverage Δ
src/index.tsx 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8680383...86f5b7b. Read the comment docs.

@diegohaz diegohaz merged commit 19e6b6a into master Sep 8, 2020
@diegohaz diegohaz deleted the feat/ts-4 branch September 8, 2020 05:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Better Typescript types Limit to the number of split values?
2 participants