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

Monorepo Phase 2 #7434

Merged
merged 63 commits into from Feb 18, 2021
Merged

Monorepo Phase 2 #7434

merged 63 commits into from Feb 18, 2021

Conversation

jansiegel
Copy link
Member

@jansiegel jansiegel commented Dec 14, 2020

Context

Additional scripts and functionalities for the monorepo.

Known issues:

  1. The Codesandbox CI script is currently not working properly, because of its use of npm@<7, which makes it impossible to utilize the npm workspaces functionality. It has been temporarily configured to build only handsontable.
  2. The @handsontable/angular package displays warnings during the build. It's caused by using Node 14+ and the stylus dependency of Angular 9. The warnings were fixed in the latest version of stylus, but it would require us to update to Angular 10.

Related issue(s):

  1. Monorepo Phase 1 #7425
  2. Introducing a monorepo. #7380

Checklist:

  • My code follows the code style of this project,
  • My change requires a change to the documentation.

  i. @handsontable/angular
  ii. @handsontable/react
  iii. @handsontable/vue
 to the './wrappers/' subdirectory,
- Configure npm workspaces for the wrappers,
- Add a link to the root directory under './packages/handsontable', because of an issue with generating 'package-lock.json',
- Add scripts for:
  i. running commands on specific projects
  ii. running commands for all projects
  iii. recognizing the context for running tests only for specific projects
- Add the config for Codesandbox CI,�
- Update some of the dependencies, to be compatible with npm@7's auto-installing peerDependencies,
- Modify and/or create issue templates, PR templates and other content,
- Update urls to the wrappers in READMEs,
- Add (and temporarily disable) new eslint options.
 (#7380)
- Modify the packages' dependencies to fix npm audit errors.
 #7380
- Add a first version of the release-scheduling script (will be extended with bundle verification etc)
 #7380
- add some dependency adjustment, needed after introducing the monorepo,
- rearrange and refactor the helper scripts,
- add a build verification script,
- add a cleaning script,
- add a "freeze" script,
- update the versioning script.
- Unify the typescript version across the packages�.
- Clean up some of the unused dependencies.
- Bump some versions to be compatible with the typescript version.
- Bump the angular version to 9 (along with some of the dependencies) in the angular wrapper + disable Ivy for compatibility.
- Add npm scripts for freezing, releasing and publishing + unify their naming between the packages.
- Rename the scripts from camelCase to kebab-case.
- Modify the freezing script with the commit/push functionality, along with some fixes.
- Add a release script.
- Modify the angular wrapper's version static to make it work with older TS versions, after changing its' dependency from Angular 8 to Angular 9.
- Modify the GH actions config to use Node 15 instead of 12.
…in the future)

- Remove the wrapper entries from the codesandbox config (temporarily)
- Add a safenet to the release script to prevent accidental release pushes to master (the --push argument)
- Add a script to re-link local packages in node_modules (needed after the modularization merge)
- Add a eslint-disabling comment to one of the files (bug in the eslint-plugin-import package)
… script exists).

- Simplify some scripts.
- Add the changelog entry.
- Correct the codesandbox ci script, to (temporarily) build only handsontable.
@codesandbox-ci
Copy link

codesandbox-ci bot commented Jan 26, 2021

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 4fcbf3e:

Sandbox Source
vanilla-handsontable-pr Configuration

- Add a forced handsontable build in the targeted test script.
- Add an error message in the node_modules linking script.
- Refresh package-lock.
- Fix the delegate-command script.
@jansiegel jansiegel marked this pull request as ready for review January 26, 2021 15:40
@jansiegel jansiegel mentioned this pull request Jan 26, 2021
6 tasks
wrappers/vue-handsontable/.release.json Outdated Show resolved Hide resolved
wrappers/vue-handsontable/.travis.yml Outdated Show resolved Hide resolved
.codesandbox/ci.json Show resolved Hide resolved
scripts/clean.js Outdated Show resolved Hide resolved
scripts/common.js Outdated Show resolved Hide resolved
scripts/freeze.js Outdated Show resolved Hide resolved
scripts/release.js Outdated Show resolved Hide resolved
scripts/run-targeted-tests.js Outdated Show resolved Hide resolved
scripts/swap-package-links.js Outdated Show resolved Hide resolved
wrappers/angular-handsontable/.travis.yml Outdated Show resolved Hide resolved
@budnix
Copy link
Member

budnix commented Jan 28, 2021

Ok, I can continue my insight, and here are my thoughts:

  • I have a problem running Vue and React unit tests npm run in vue test. Hence the npm run test:all crashes;
  • There is a lot of new scripts in the scripts directory. Can we add a header with a description of what the script does? For example set-version script bumps not only the version field in the package.json file but bumps the Handsontable dev and peer dependency;

.eslintrc.js Show resolved Hide resolved
- Get rid of all eslint-disabling comments in favor of a eslint exceptions for the 'scripts' directory.
- Correct the targeted tests script to accept commits with no projects changed.
- Extend yargs config for the targeted tests script.
Co-authored-by: Krzysztof Budnik <571316+budnix@users.noreply.github.com>
scripts/freeze.mjs Outdated Show resolved Hide resolved
@budnix budnix self-requested a review February 15, 2021 13:06
@budnix budnix assigned jansiegel and unassigned budnix Feb 15, 2021
scripts/swap-package-links.mjs Outdated Show resolved Hide resolved
Co-authored-by: Wojciech Czerniak <wojciech.czerniak@gmail.com>
Copy link
Member

@budnix budnix left a comment

Choose a reason for hiding this comment

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

After the long journey, I'm happy to accept the changes :) Good job 👍

Copy link
Contributor

@wojciechczerniak wojciechczerniak left a comment

Choose a reason for hiding this comment

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

🏆

@jansiegel jansiegel merged commit 8b600db into develop Feb 18, 2021
@jansiegel jansiegel deleted the feature/issue-7380-phase-2 branch February 18, 2021 08:03
@krzysztofspilka
Copy link
Member

krzysztofspilka commented Feb 18, 2021

Nicely done @jansiegel

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.

None yet

4 participants