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

Storybook with Angularjs (1.x)? #3508

Closed
mdwagner opened this issue Apr 30, 2018 · 7 comments
Closed

Storybook with Angularjs (1.x)? #3508

mdwagner opened this issue Apr 30, 2018 · 7 comments

Comments

@mdwagner
Copy link

Hello! I've been using React-Storybook for a few small projects now and love it. However, at my work we still use Angularjs (1.x) and we'll be (incrementally) migrating to React soon. Currently, we use Hologram for rendering Angularjs component documentation, but we would like to migrate to something else (hopefully Storybook).

I was wondering what your suggestion(s) are for using Storybook with Angularjs, along with getting addons working. This example is the best I could come up with, but I can only get the withConsole addon to work with it.

Thank you for your time!

@ersel
Copy link
Contributor

ersel commented Apr 30, 2018

Interesting, we're also migrating from 1.x to React at my workplace. I think your approach is to render Angular within React components?

We're doing the exact opposite, using the https://github.com/ngReact/ngReact

It lets us build new components in React and slowly migrate existing bits iteratively. So we can use all the modern tooling around the React components.

@mdwagner
Copy link
Author

mdwagner commented Apr 30, 2018

Yeah, we were initially going to use ngReact for migration, but we felt that it didn't fulfill our requirements, only developer happiness. Our migration approach will be to use UI-Router/React-Hybrid because our app is too large to migrate at one time and we wanted to take control away from Angularjs and move to a more framework-agnostic router.

My approach was to use React to render Angularjs. That's the best I could come up with, other than to maybe make something for Storybook?

@wuweiweiwu
Copy link
Member

wuweiweiwu commented May 5, 2018

As angular1.x will be defunct in 3 years https://blog.angular.io/stable-angularjs-and-long-term-support-7e077635ee9c I'm not sure if we should add support.

I feel your pain too haha. We're still on angular1.x w no migration in sight :(

@Hypnosphi
Copy link
Member

@storybook/html may bring some hope

@stale
Copy link

stale bot commented May 28, 2018

Hi everyone! Seems like there hasn't been much going on in this issue lately. If there are still questions, comments, or bugs, please feel free to continue the discussion. Unfortunately, we don't have time to get to every issue. We are always open to contributions so please send us a pull request if you would like to help. Inactive issues will be closed after 30 days. Thanks!

@stale stale bot added the inactive label May 28, 2018
@mdwagner
Copy link
Author

It lools like I'll use the storybook html package

@titonobre
Copy link
Contributor

titonobre commented Jul 16, 2018

@mdwagner, @ersel, @wuweiweiwu Last week I published a new addon to create stories in storybook with AngularJS components.

Check here https://github.com/titonobre/storybook-addon-angularjs
This depends on the lastest pre-realeses of Storybook, after #3475.

There is also an example of usage here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants