Magento 2 Composer Installer
, (*1)
Usage
In composer.json of the component specify:
- type - type of Magento 2 component
- extra/map - list of files to move and their location relative to the path they will be located in the application, (*2)
Supported Components
Magento Module
Type: magento2-module, (*3)
Installation location: app/code, (*4)
Example:, (*5)
{
"name": "magento/module-core",
"description": "N/A",
"require": {
...
},
"type": "magento2-module",
"extra": {
"map": [
[
"*",
"Magento/Core"
]
]
}
}
Final location will be <root>/app/code/Magento/Core, (*6)
Magento Theme
Type: magento2-theme, (*7)
Installation location: app/design, (*8)
Example:, (*9)
{
"name": "magento/theme-frontend-plushe",
"description": "N/A",
"require": {
...
},
"type": "magento2-theme",
"extra": {
"map": [
[
"*",
"frontend/Magento/plushe"
]
]
}
}
Final location will be <root>/app/design/frontend/Magento/plushe, (*10)
Magento Language Package
Type: magento2-language, (*11)
Installation location: app/i18n, (*12)
Example:, (*13)
{
"name": "magento/language-de_de",
"description": "German (Germany) language",
"require": {
...
},
"type": "magento2-language",
"extra": {
"map": [
[
"*",
"Magento/de_DE"
]
]
}
}
Final location will be <root>/app/i18n/Magento/de_DE, (*14)
Magento Library
Support for libraries located in lib/internal instead of vendor directory., (*15)
Installation location: lib/internal, (*16)
Type: magento2-library, (*17)
Example:, (*18)
{
"name": "magento/framework",
"description": "N/A",
"require": {
...
},
"type": "magento2-library",
"extra": {
"map": [
[
"*",
"Magento/Framework"
]
]
}
}
Final location will be <root>/lib/internal/Magento/Framework, (*19)
Magento Component
Default type, if none is specified., (*20)
Installation location: . (root directory of the code base), (*21)
Type: magento2-component, (*22)
Example:, (*23)
{
"name": "magento/migration-tool",
"description": "N/A",
"require": {
...
},
"type": "magento2-component",
"extra": {
"map": [
[
"*",
"tools/Magento/Migration"
]
]
}
}
Final location will be <root>/tools/Magento/Migration, (*24)