Originate / recouple

Declarative and type-safe API bridging. Write full-stack applications with ease.
MIT License
4 stars 1 forks source link

Example code should be based on published npm packages #45

Open sleexyz opened 6 years ago

sleexyz commented 6 years ago

We want the example code to be as close to what users would write. This means we should have it run against the published npm packages.

So the example directory should manage its own yarn workspaces. Therefore, we should remove it from the root set of yarn workspaces.

Do we want to share a lerna config with the root directory? Can we perhaps have both an example-specific one and the root one?

@astampoulis

astampoulis commented 6 years ago

Just thought of an issue with this: how do we run the tests before we publish? There's a circular dependency involved: in order to run the tests for a new version prior to publishing it, we depend on the new version being published.

sleexyz commented 6 years ago

Good point. Ideally there's a way to

  1. test the example project while being managed by yarn-workspaces (as part of standard CI checks)
  2. test the example project against the npm packages (as a post-release sanity check)

The first one should be straightforward. The second one might be a separate CI job (after a CI release) that would need to modify some files.