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

[Proposal] flat and intuitive component structure to simplify import statement. #2591

Closed
alitaheri opened this issue Dec 18, 2015 · 7 comments

Comments

@alitaheri
Copy link
Member

I think this format:

import CardExpandable from 'material-ui/CardExpandable';
// or
import {CardExpandable} from 'material-ui';

is much more intuitive and convenient than this:

import CardExpandable from 'material-ui/lib/card/card-expandable';

Making this happen is hard and takes a lot of time. But it's a goo plan I think.

It can only be for deployment so gitignore and development can stick to lib.

@oliviertassinari @newoga @Zadielerick What do you think about this?

@oliviertassinari
Copy link
Member

@subjectix That seems better, however, in the long run, I would prefer to use:

import {CardExpandable} from 'material-ui';

@alitaheri
Copy link
Member Author

@oliviertassinari That would require tooling. besides not every build system can handle this from client side. I think it's best to provide both formats.

I updated my proposal

@newoga
Copy link
Contributor

newoga commented Dec 19, 2015

Yup, I can't argue with this. I like both approaches more than what we currently have.

@alitaheri
Copy link
Member Author

@newoga Cool. after my marathon on the theme handling, I'll move onto improving the build script, upgrading to babel 6. updating dependencies and related housework stuff.

@Zadielerick
Copy link
Contributor

@newoga @oliviertassinari Yes, both of these sound pretty easy to implement, I think I know how to make either one happen.

@oliviertassinari
Copy link
Member

I'll move onto improving the build script, upgrading to babel 6

I'm already on it 👍 (needed for react-native)

@alitaheri
Copy link
Member Author

Discussion moved to #3682

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

4 participants