Skip to content

Conversation

@remcohaszing
Copy link
Member

Since the migration to TypeScript, examples had to be adjusted. The SDK now uses named exports. Also the SDK needs to be built before examples can be run. This is now displayed on top of the example instructions.

Since the SDK now used package exports, the examples can now import the package using its name instead of relative imports.

Some ESLint warnings have been disabled for the examples.

Incorrect paths to example fixtures have been fixed.

The examples are now type-checked using JSDoc based type annotations.

Closes #204

Since the migration to TypeScript, examples had to be adjusted. The SDK
now uses named exports. Also the SDK needs to be built before examples
can be run. This is now displayed on top of the example instructions.

Since the SDK now used package exports, the examples can now import the
package using its name instead of relative imports.

Some ESLint warnings have been disabled for the examples.

Incorrect paths to example fixtures have been fixed.

The examples are now type-checked using JSDoc based type annotations.

Closes #204
@remcohaszing remcohaszing requested review from Acconut and kvz December 6, 2024 14:22
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.75%. Comparing base (4daf1c5) to head (2875a6d).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #205   +/-   ##
=======================================
  Coverage   68.75%   68.75%           
=======================================
  Files           6        6           
  Lines         624      624           
  Branches      123      123           
=======================================
  Hits          429      429           
  Misses        195      195           
Flag Coverage Δ
unittests 68.75% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@Acconut Acconut left a comment

Choose a reason for hiding this comment

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

Thank you for this quick PR! It looks good to me and I just have a minor question.

authSecret: /** @type {string} */ (process.env.TRANSLOADIT_SECRET),
// authKey: /** @type {string} */ (process.env.API2_SYSTEMTEST_AUTH_KEY),
// authSecret: /** @type {string} */ (process.env.API2_SYSTEMTEST_SECRET_KEY),
// endpoint: /** @type {string} */ ('https://api2-vbox.transloadit.com'),
Copy link
Contributor

Choose a reason for hiding this comment

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

The three values that are commented out are the result from internal from other repositories and don't serve a purpose for our users. Should we just remove them here?

Copy link
Member Author

Choose a reason for hiding this comment

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

I kept it as-is, but I agree this should probably be removed.

@remcohaszing remcohaszing merged commit 9bf67d4 into main Dec 9, 2024
9 checks passed
@remcohaszing remcohaszing deleted the fix-examples branch December 9, 2024 14:48
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.

Instructions for running examples don't work

5 participants