fermyon / spin-js-sdk

https://developer.fermyon.com/spin/javascript-components
Apache License 2.0
52 stars 18 forks source link

WIP: POC for new sdk js lib implementation #159

Closed karthik2804 closed 1 year ago

karthik2804 commented 1 year ago

This is a very work-in-progress implementation of the SDK lib. This PR attempts to replace the current spin-sdk package which hosts only type to a package that provides implementations as well. This allows for there to be an explicit import of types in both ts/js as per #158.

Currently, there are examples for both ts/js In

The advantage to this is that helper functions can be added without a need for there to be a new build of the plugin along with allowing us to create explicit imports allowing for the removal of magic imports.

The one downside to this approach is that there will be slightly more work maintaining both the code that is internal to the SDK as well as this package.

There definitely needs to be a lot more of the cleanup if this is an approach we want to pursue.

Thoughts?