-
Notifications
You must be signed in to change notification settings - Fork 139
Folder restructure AKA "The Flattening" #142
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few minor things, but otherwise this looks 🥇 fantastic 🥇
Co-Authored-By: robinheinze <robinheinze@users.noreply.github.com>
Co-Authored-By: robinheinze <robinheinze@users.noreply.github.com>
Co-Authored-By: robinheinze <robinheinze@users.noreply.github.com>
I merged @bryanstearns 's PR #141 which introduced conflicts to this one, apologies @robinheinze . |
I don't know if off topic. But, will this pr break old project if i update boilerplate to this version? |
@guhungry The only thing I can think of would be generators trying to place files in directories that don't exist. I will make sure it creates the directory if it doesn't find it. Thanks for noticing that! |
@guhungry Just verified that the generators are all backwards compatible, so I don't believe anything will break if you were to update the boilerplate to this version in an existing project. You can always pin the version though if you'd like to keep using the old structure. |
@robinheinze Thanks. Sorry fore more question. How about |
@guhungry I think it might have trouble with that, but I haven't verified for sure. In general, some things may work, but we really aren't guaranteeing backwards compatibility with a major version bump like this (this will be 3.0.0). The safest thing to do if you have an existing project is to pin your boilerplate version to 2.0.3 (although I think NPM/Yarn should keep you safe from automatic major version upgrades anyway). |
# [2.1.0](v2.0.3...v2.1.0) (2019-01-22) ### Features * **project:** Folder restructure AKA "The Flattening" ([#142](#142)) by [@robinheinze](https://github.com/robinheinze) ([71c6ccc](71c6ccc)) * **setup:** Add setup script ([#144](#144)) by [@mlaco](https://github.com/mlaco) [skip ci] ([28856f1](28856f1))
🎉 This PR is included in version 2.1.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Gah, why ... why .... 😦 I'll fix |
…inheinze BREAKING CHANGE: * Re-organized folder structure in boilerplate * Adjusted generators for new folder structure Other notable changes: * Updated READMEs to reflect new folder structure * Remove extraneous config files from root
# [3.0.0](v2.0.3...v3.0.0) (2019-01-22) ### Features * **project:** Folder restructure AKA "The Flattening" ([#142](#142)) by [@robinheinze](https://github.com/robinheinze) ([98ba911](98ba911)) * **setup:** Add setup script ([#144](#144)) by [@mlaco](https://github.com/mlaco) [skip ci] ([28856f1](28856f1)) ### BREAKING CHANGES * **project:** * Re-organized folder structure in boilerplate * Adjusted generators for new folder structure Other notable changes: * Updated READMEs to reflect new folder structure * Remove extraneous config files from root
import { Reactotron } from "../services/reactotron" | ||
import { Api } from "../services/api" | ||
import { Environment } from "../environment" | ||
import * as storage from "../..//utils/storage" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
two slashes typo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mangei Would you mind sending in a PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just read this. Thanks @dashracer for fixing it! :)
This will be for version 3.0
In this new structure, screens will still be in folders co-located with any assets, but components will all live under
/components
, even if they are specific to a screen. Storybook and assets will also still be co-located with each component. We would also remove the concept of “domain” from the generators, which should make things a bit clearer.Note: This is the top level directory. We removed
./src/app
and all of the actual app content now lives under simply./app
. The rest of the top level directory is unchanged and still containsios
,android
,ignite
,storybook
, andtest
directories.Biggest differences
./src
to./app
. For the files that were previously in./src/app
:main.tsx
androot-component.tsx
into oneapp.tsx
which lives at the root of./app
setup-root-store.ts
into./app/models/root-store/
./src/views
into./app/screens
and./app/components
. Screen and component generators will place all new components and screens in these two folders../lib
to./utils