Magento – There are no commands defined in the “setup:static-content” namespace

-setupmagento2static-content

There are no commands defined in the "setup:static-content" namespace.

Did you mean one of these?

  setup
  setup:config
  setup:cron
  setup:db-data
  setup:db-schema
  setup:db
  setup:di
  setup:performance
  setup:store-config

When Run deploy Command in Magento 2 show error in console?

Best Answer

first run the cmd composer install in you folder then run this cmd

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy (or) 
php bin/magento setup:static-content:deploy -f
php bin/magento indexer:reindex
php bin/magento cache:flush (or)
php bin/magento cache:clean

after setup:upgrade you remove the generation, page_cache, cache, view_preprocessed, static rm -rf var/generation/* var/cache/* var/report/* var/page_cache/* pub/static/* var/view_preprocessed/* `

Related Topic