src/Plugin.php
protected function afterInstall()
    {
        $configSourceFile = __DIR__ . DIRECTORY_SEPARATOR . 'config.example.php';
        $configTargetFile = \Craft::$app->getConfig()->configDir . DIRECTORY_SEPARATOR . $this->handle . '.php';

        if (!file_exists($configTargetFile)) {
            copy($configSourceFile, $configTargetFile);
        }
    }
protected function afterInstall()
    {
        $configSourceFile = __DIR__ . DIRECTORY_SEPARATOR . 'config.example.php';
        $configTargetFile = \Craft::$app->getConfig()->configDir . DIRECTORY_SEPARATOR . $this->handle . '.php';

        if (!file_exists($configTargetFile)) {
            copy($configSourceFile, $configTargetFile);
        }
    }
protected function afterInstall ( ) { $ configSourceFile = __DIR__ . DIRECTORY_SEPARATOR . 'config.example.php' ; $ configTargetFile = \ Craft :: $ app -> getConfig ( ) -> configDir . DIRECTORY_SEPARATOR . $ this -> handle . '.php' ; if ( ! file_exists ( $ configTargetFile ) ) { copy ( $ configSourceFile , $ configTargetFile ) ; } }
Is called after the plugin is installed.
Copies example config to project's config folder
Is called after the plugin is installed . Copies example config to project s config folder