Skip to content

Instantly share code, notes, and snippets.

@batazor
Last active August 29, 2015 14:17
Show Gist options
  • Save batazor/048238e034a2d8a0e32d to your computer and use it in GitHub Desktop.
Save batazor/048238e034a2d8a0e32d to your computer and use it in GitHub Desktop.
Architecture.txt
.
├── /src/ # The source code of the application
│ ├── /actions/ # Action creators that allow to trigger a dispatch to stores
| ├── /assets/ # Static files which are copied to ./build on compile
│ ├── /components/ # React components
│ ├── /constants/ # Enumerations used in action creators and stores
│ ├── /content/ # Website content (plain HTML or Markdown, Jade, you name it)
│ ├── /core/ # Core components (Flux dispatcher, base classes, utilities)
│ ├── /dispatcher/ # Dispatcher
│ ├── /stores/ # Stores contain the application state and logic
│ ├── /templates/ # HTML templates for server-side rendering, emails etc.
│ ├── /models/ # Mongoose models
│ | ├── /user.js
│ | ├── /message.js
│ | └── /chatroom.js
│ ├── /app.js # Client-side startup script
│ ├── /server.js # Server-side startup script
│ └── /routes.js # Routing Server
├── .gitignore # A gitignore file specifies untracked files
├── package.json # The list of 3rd party libraries and utilities
├── gulpfile.js # Configuration file for automated builds
└── README.md # README
@koistya
Copy link

koistya commented Mar 22, 2015

Check out this folder layout:

https://github.com/kriasoft/react-starter-kit

@koistya
Copy link

koistya commented Mar 23, 2015

По Rev. #4:
  • Обычно в проекте веб приложения есть либо /src/, либо /app/ папка для сырцов. /app/ если планируется что веб-приложение будет запускаться прямо из этой папки и /src/ если планируется что сайт будет полностью собираться в другую временную папку (например, /build/ или /dist/) и уже запускаться оттуда.
  • Папку /src/styles/ можно покоцать в пользу CSS стилей на уровне React.js компонентов, таким образом можно избежать потенциальных проблем с shared стилями.

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