Answer the question
In order to leave comments, you need to log in
Do I need to specify vendor_name/package_name when creating a package?
I got lost in three pines, although I thought that I knew everything.
When I was looking into composer, I was looking at third party packages on packagist.org and noticed a trend that packages are named as vendor_name/package_name :
"autoload-dev": {
"psr-4": {
"Vendor\\Library\\": "src"
}
},
A fully qualified class name must have the following structure: \<Namespace>(\<SubNamespace>)*\<ClassName>- roughly speaking, the standard requires only specifying the Supplier in the <Namespace>, and what <SubNamespace> will be - no one cares.
"require": {
"yiisoft/yii2": "~2.0.6",
"yiisoft/yii2-bootstrap": "~2.0.0",
"yiisoft/yii2-swiftmailer": "~2.0.0 || ~2.1.0"
},
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question