Skip to content

Commit 0cc4572

Browse files
committed
docs: update README and add advanced usage guide for improved clarity and tips 📝
1 parent e358562 commit 0cc4572

2 files changed

Lines changed: 116 additions & 56 deletions

File tree

README.md

Lines changed: 29 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
1-
# MageForge for Magento 2 (Beta)
1+
# MageForge for Magento 2
22

33
![Mageforge Hero](./.github/assets/mageforge-hero.jpg)
44

55
[![Codacy Badge](https://app.codacy.com/project/badge/Grade/7d7c46d7492043c7ada514ed1d4a4c05)](https://app.codacy.com/gh/OpenForgeProject/mageforge/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade) [![CodeFactor](https://www.codefactor.io/repository/github/openforgeproject/mageforge/badge)](https://www.codefactor.io/repository/github/openforgeproject/mageforge)
66

7-
MageForge is a Magento 2 module designed to assist frontend developers in streamlining their workflow and enhancing productivity.
8-
9-
---
7+
MageForge is a powerful CLI front-end development toolkit for Magento 2 that simplifies theme development workflows. It provides tools for many types of Magento themes and can be easily extended for your custom theme. With MageForge, themes can be built lightning fast, without your developers having to worry about the details. MageForge eliminates complex configuration requirements and significantly reduces setup time, allowing Magento developers to focus on creative aspects instead of struggling with build processes.
108

119
[![Join our OpenForgeProject Discord community](./.github/assets/small_logo_blurple_RGB.png)](https://discord.gg/H5CjMXQQHn)
1210

13-
## Magento Requirements
11+
## Supported Magento Versions
1412

1513
MageForge requires Magento 2.4.7 or higher.
1614
Please ensure that your Magento installation meets this requirement before installation.
@@ -47,82 +45,57 @@ Please ensure that your Magento installation meets this requirement before insta
4745
---
4846

4947
## Getting Started
50-
### Installation
5148

52-
Install the module via Composer:
53-
```bash
54-
composer require openforgeproject/mageforge
55-
```
49+
### Installation
5650

57-
Enable the module:
58-
```bash
59-
bin/magento module:enable OpenForgeProject_MageForge
60-
bin/magento setup:upgrade
61-
```
51+
1. Install the module via Composer:
52+
```bash
53+
composer require openforgeproject/mageforge
54+
```
6255

63-
## Getting Started
56+
2. Enable the module:
57+
```bash
58+
bin/magento module:enable OpenForgeProject_MageForge
59+
bin/magento setup:upgrade
60+
```
6461

65-
### Theme Development
62+
### Quick Start Guide
6663

67-
1. List all available themes:
64+
1. List available themes:
6865
```bash
6966
bin/magento mageforge:theme:list
7067
```
7168

72-
2. Build a specific theme:
69+
2. Build a theme:
7370
```bash
7471
bin/magento mageforge:theme:build <theme-code>
7572
```
7673
Example: `bin/magento mageforge:theme:build Magento/luma`
7774

78-
3. Start watch mode for development:
75+
3. Start development watch mode:
7976
```bash
8077
bin/magento mageforge:theme:watch <theme-code>
8178
```
8279

83-
### Supported Theme Types
84-
85-
- **Magento Standard Themes**: LESS-based themes
86-
- **Hyvä Themes**: Tailwind CSS based themes
87-
- **Custom Tailwind Themes**: Standalone Tailwind implementations
88-
89-
### Tips & Tricks
90-
91-
- Use the `-v` option for more detailed output
92-
- Watch mode supports hot-reloading for LESS and Tailwind
93-
- Check system information anytime with `mageforge:system:check`
94-
- Use shortcodes for faster command execution, for example `bin/magento m:t:b` instead of `bin/magento mageforge:theme:build`
95-
- Theme build and watch commands have special aliases: `frontend:build` and `frontend:watch`
96-
97-
## Extending MageForge
98-
99-
MageForge provides a modular architecture that allows developers to create custom theme builders for specific project requirements. For more information, see:
100-
101-
- [Custom Theme Builders Documentation](./docs/custom_theme_builders.md)
102-
- [Commands Documentation](./docs/commands.md)
103-
104-
## Report Feature or Bugs
105-
106-
MageForge provides several forms to submit feature requests or report a bug.
107-
You will find it in the [issue section](https://github.com/OpenForgeProject/mageforge/issues) of GitHub.
108-
109-
## Contributing
110-
111-
We welcome contributions from the community! Please see our [Contributing Guidelines](./CONTRIBUTING.md) for more information on how to get involved.
80+
4. Enjoy automatic CSS rebuilding you work on your theme files!
11281

113-
## License
82+
## Additional Documentation
11483

115-
See the [LICENSE](LICENSE) file for more details.
84+
- [Advanced Usage Guide](./docs/advanced_usage.md) - Tips, tricks and troubleshooting
85+
- [Custom Theme Builders Documentation](./docs/custom_theme_builders.md) - Extend MageForge for your custom themes
86+
- [Commands Documentation](./docs/commands.md) - Detailed command reference
11687

117-
## Support
88+
## Community & Support
11889

119-
For support, please open an issue on the [GitHub repository](https://github.com/OpenForgeProject/mageforge/issues) or join our [Discord community](https://discord.gg/H5CjMXQQHn).
90+
- **Report Bugs/Features**: [GitHub Issues](https://github.com/OpenForgeProject/mageforge/issues)
91+
- **Get Help**: [Discord Community](https://discord.gg/H5CjMXQQHn)
92+
- **Contributing**: See [Contributing Guidelines](./CONTRIBUTING.md)
12093

121-
## Changelog
94+
## Project Information
12295

123-
All notable changes to this project will be documented in the [CHANGELOG](CHANGELOG.md) file.
96+
- **License**: [LICENSE](LICENSE)
97+
- **Changelog**: [CHANGELOG](CHANGELOG.md)
12498

12599
---
126100

127101
Thank you for using MageForge!
128-
We hope it makes your development process smoother and more efficient.

docs/advanced_usage.md

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
# MageForge Advanced Usage
2+
3+
This document provides detailed information and advanced tips for using MageForge effectively in your Magento 2 development workflow.
4+
5+
## Theme Development Tips
6+
7+
### Command Efficiency
8+
9+
- Use shortcodes for faster command execution:
10+
- `m:t:b` instead of `mageforge:theme:build`
11+
- `m:t:w` instead of `mageforge:theme:watch`
12+
- `m:s:c` for system check
13+
14+
- Alternative aliases for common commands:
15+
- `frontend:build` for `mageforge:theme:build`
16+
- `frontend:watch` for `mageforge:theme:watch`
17+
18+
### Development Workflow
19+
20+
1. **System Check**: Before starting development, run a system check:
21+
```bash
22+
bin/magento mageforge:system:check
23+
```
24+
25+
2. **Enhanced Output**: Use the `-v` option for more detailed information during builds:
26+
```bash
27+
bin/magento mageforge:theme:build <theme-code> -v
28+
```
29+
30+
3. **Hot-reloading**: Watch mode automatically detects changes and rebuilds:
31+
- For LESS files in standard Magento themes
32+
- For Tailwind-based templates in Hyvä themes
33+
- For custom CSS implementations
34+
35+
## Theme Type Specifics
36+
37+
### Standard Magento Themes (LESS)
38+
39+
For traditional LESS-based Magento themes, MageForge handles:
40+
- LESS compilation
41+
- Source map generation
42+
- Minification for production
43+
44+
### Hyvä Themes (Tailwind CSS)
45+
46+
MageForge streamlines Hyvä theme development with:
47+
- Automatic TailwindCSS compilation
48+
- PurgeCSS optimization
49+
- Component scanning
50+
51+
### Custom Tailwind CSS Implementations
52+
53+
For custom Tailwind setups (non-Hyvä), MageForge supports:
54+
- Custom Tailwind configuration
55+
- PostCSS processing
56+
- Custom directory structures
57+
58+
### Avanta B2B Theme
59+
60+
MageForge has special support for Avanta B2B themes with:
61+
- B2B-specific component scanning
62+
- Special optimization for B2B module templates
63+
64+
## Performance Optimization
65+
66+
- Build specific theme components instead of entire themes for faster development
67+
- Use the production flag for minified, optimized output when ready for deployment
68+
- Consider selective watching for large themes to improve performance
69+
70+
## Troubleshooting
71+
72+
Common issues and solutions:
73+
74+
1. **Build Failures**:
75+
- Ensure Node.js is installed and available
76+
- Check for syntax errors in LESS or CSS files
77+
- Verify Tailwind configuration is valid
78+
79+
2. **Watch Mode Issues**:
80+
- Check file permissions
81+
- Ensure no conflicting processes are running
82+
83+
3. **Integration Problems**:
84+
- Clear Magento cache after theme builds
85+
- Verify theme registration in Magento
86+
87+
For more help, join our [Discord community](https://discord.gg/H5CjMXQQHn) or open an issue on GitHub.

0 commit comments

Comments
 (0)