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(operators): improve publicly exposed types #1956

Merged
merged 1 commit into from
Dec 12, 2022

Conversation

markwhitfeld
Copy link
Member

@markwhitfeld markwhitfeld commented Dec 12, 2022

## PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Issue Number: #1715

What is the new behavior?

  • Expose the necessary State Operator types for the consumer of the API to more easily
    construct their own State Operators.
  • Hide the AsReadOnly type so that the typescript error messaging is not referring to an internal type.
  • Expose the PatchSpec type with a barred O notation so that it can be used externally, but it used with caution in case the internal type representation changes.

Does this PR introduce a breaking change?

[ ] Yes
[x] No

Other information

@bundlemon
Copy link

bundlemon bot commented Dec 12, 2022

BundleMon

Files updated (1)
Status Path Size Limits
fesm2015/ngxs-store-operators.js
6.23KB (+13B +0.2%) 15KB / +0.5%
Unchanged files (2)
Status Path Size Limits
fesm2015/ngxs-store.js
88.88KB 125KB / +0.5%
fesm2015/ngxs-store-internals.js
4.22KB 20KB / +0.5%

Total files change +13B +0.01%

Groups updated (1)
Status Path Size Limits
@ngxs/store(esm2015)[gzip]
./esm2015/**/*.js
166.82KB (+461B +0.27%) +1%
Unchanged groups (2)
Status Path Size Limits
@ngxs/store(umd)[gzip]
./bundles/*.umd.js
35.32KB +1%
@ngxs/store(fesm2015)[gzip]
./fesm2015/*.js
24.02KB +1%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

@bundlemon
Copy link

bundlemon bot commented Dec 12, 2022

BundleMon (NGXS Plugins)

Unchanged files (14)
Status Path Size Limits
Plugins(umd)[gzip]
storage-plugin/bundles/ngxs-storage-plugin.um
d.js
7.96KB +1%
Plugins(umd)[gzip]
router-plugin/bundles/ngxs-router-plugin.umd.
js
7.41KB +1%
Plugins(umd)[gzip]
websocket-plugin/bundles/ngxs-websocket-plugi
n.umd.js
6.92KB +1%
Plugins(umd)[gzip]
hmr-plugin/bundles/ngxs-hmr-plugin.umd.js
6.89KB +1%
Plugins(fesm2015)[gzip]
storage-plugin/fesm2015/ngxs-storage-plugin.j
s
3.64KB +1%
Plugins(umd)[gzip]
form-plugin/bundles/ngxs-form-plugin.umd.js
3.41KB +1%
Plugins(fesm2015)[gzip]
router-plugin/fesm2015/ngxs-router-plugin.js
3.09KB +1%
Plugins(umd)[gzip]
devtools-plugin/bundles/ngxs-devtools-plugin.
umd.js
2.75KB +1%
Plugins(fesm2015)[gzip]
form-plugin/fesm2015/ngxs-form-plugin.js
2.65KB +1%
Plugins(fesm2015)[gzip]
hmr-plugin/fesm2015/ngxs-hmr-plugin.js
2.65KB +1%
Plugins(fesm2015)[gzip]
websocket-plugin/fesm2015/ngxs-websocket-plug
in.js
2.59KB +1%
Plugins(umd)[gzip]
logger-plugin/bundles/ngxs-logger-plugin.umd.
js
2.53KB +1%
Plugins(fesm2015)[gzip]
devtools-plugin/fesm2015/ngxs-devtools-plugin
.js
2.17KB +1%
Plugins(fesm2015)[gzip]
logger-plugin/fesm2015/ngxs-logger-plugin.js
2.01KB +1%

No change in files bundle size

Unchanged groups (3)
Status Path Size Limits
All Plugins(esm2015)[gzip]
./-plugin/esm2015/**/.js
108.45KB +1%
All Plugins(umd)[gzip]
./-plugin/bundles/.umd.js
37.88KB +1%
All Plugins(fesm2015)[gzip]
./-plugin/fesm2015/.js
18.8KB +1%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

@bundlemon
Copy link

bundlemon bot commented Dec 12, 2022

BundleMon (Integration Projects)

Unchanged files (3)
Status Path Size Limits
Main bundles(Gzip)
hello-world-ng13-ivy/dist-integration/main.(h
ash).js
69.83KB +1%
Main bundles(Gzip)
hello-world-ng12-ivy/dist-integration/main.(h
ash).js
67.99KB +1%
Main bundles(Gzip)
hello-world-ng14-ivy/dist-integration/main.(h
ash).js
65.5KB +1%

No change in files bundle size

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

@codeclimate
Copy link

codeclimate bot commented Dec 12, 2022

Code Climate has analyzed commit c592331 and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 97.0% (0.0% change).

View more on Code Climate.

Copy link
Member

@arturovt arturovt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love comments

@arturovt arturovt merged commit 40a2210 into master Dec 12, 2022
@arturovt arturovt deleted the mark/improve-operator-types branch December 12, 2022 10:31
@markwhitfeld markwhitfeld added this to the v3.8.0 milestone Mar 29, 2023
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.

2 participants