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: interactive docs using Pitsby #61

Merged
merged 16 commits into from
Aug 11, 2022
Merged

feat: interactive docs using Pitsby #61

merged 16 commits into from
Aug 11, 2022

Conversation

jessicamcinchak
Copy link
Member

@jessicamcinchak jessicamcinchak commented Sep 26, 2021

trying out Pitsby as a much lighter alternative to storybook that supports vanilla web components (Closes #26)

deployed here: https://deploy-preview-61--oslmap.netlify.app/#!/components/vanilla

get up & running locally:

  • checkout branch, pnpm i to add new pitsby dependency
  • pnpm run docs builds the docs in watch mode & listens for changes; site is running at https://localhost:7000
  • pnpm docsPublish builds the docs so they can be served as a static site from pitsby/

deploying the docs:
I've updated Netlify "deploy settings" to publish the component library instead of the index.html sandbox (that's still around for local dev though). I additionally removed our OS API keys from Netlify, otherwise Pitsby would read them & put them in plaintext in the "template" section. These docs are a bring-your-own-API-key situation!

https://app.netlify.com/sites/oslmap/settings/deploys

before:
Screenshot from 2022-08-05 12-47-18

after:
Screenshot from 2022-08-05 12-55-05

future cleanup:

  • build out more examples - custom styles using css overrides, more recent map properties, etc
  • what's happening with os features examples? why is data synced?
  • geojsonData example not loading?
  • some way to handle env vars / OS API keys?
  • typescript support?

@netlify
Copy link

netlify bot commented Sep 26, 2021

Deploy Preview for oslmap ready!

Name Link
🔨 Latest commit 5758eb1
🔍 Latest deploy log https://app.netlify.com/sites/oslmap/deploys/62f50a091de0c0000973c3b5
😎 Deploy Preview https://deploy-preview-61--oslmap.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@jessicamcinchak jessicamcinchak requested a review from a team August 5, 2022 10:58
@jessicamcinchak jessicamcinchak marked this pull request as ready for review August 5, 2022 10:58
package.json Outdated
Comment on lines 22 to 24
"prepare": "husky install",
"docs": "NODE_ENV=development pitsby build --watch",
"docsPublish": "pitsby build"
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

Copy link
Contributor

@DafyddLlyr DafyddLlyr left a comment

Choose a reason for hiding this comment

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

This is great, and super nice to use! A big improvement and a solid step forward.

The future cleanup section of your PR was great - I hit the same issues but totally think that's a next step to look at as opposed to doing it all here.

package.json Outdated Show resolved Hide resolved
pitsby/index.html Outdated Show resolved Hide resolved
@jessicamcinchak jessicamcinchak merged commit 41122aa into main Aug 11, 2022
@jessicamcinchak jessicamcinchak deleted the jess/docs-pitsby branch August 11, 2022 13:58
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.

Add different examples
2 participants