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

V1.4.1 #35

Merged
merged 19 commits into from
Apr 17, 2024
Merged

V1.4.1 #35

merged 19 commits into from
Apr 17, 2024

Conversation

Adedoyin-Emmanuel
Copy link
Owner

PR Summary

The patch version 1.4.1 aims to fix issues related to the components and pages generation.

  1. React Components and Pages as well as NextJs Components, Pages name default to index.jsx or index.tsx if generateFolder configuration is specified. This makes components and pages import cleaner and easier to understand. For example, if you generate a component called Button, the generated component path would be Button/index.jsx or Button/index.tsx and you can import it like this import Button from './components/Button'. Unlike before where you would have to import it like this import Button from './components/Button/Button'.
  2. Fixed component and page capitalization issues. In previous versions of Methane, if you generate a component called button, the file name remains button but the generated component would be button instead of Button. This has been fixed in this version.
  3. Gracefully handled potential errors that might occur when generating pages or components.
  4. Added a new argument -d or --default to methane init command. This allows developers to easily initialize Methane with the default configuration without being prompted to answer questions. This is useful when you want to quickly initialize Methane in a new project. Note You can always update the Methane configuration by running methane config command.

= added 19 commits April 17, 2024 02:23
This will allow users to skip methane init prompt and use default configurations.
…default file name if user-config generateFolder is set to true

Added a conditional to check if the user config has the generate folder set to true, hence the page file name is set to index.jsx or index.tsx (depending on user config).
This will make the import statements cleaner and only name the page if the generateFolder is set to false
… use index as default filename if generateFolder config is set
… as default filename if generateFolder config is set
…on to use index as default filename if generateFolder config is set
@Adedoyin-Emmanuel Adedoyin-Emmanuel merged commit b319c3d into master Apr 17, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant