Assets::register( $container )

Summary

No summary available.

Source

File: src/BigCommerce/Container/Assets.php

	public function register( Container $container ) {
		$container[ self::PATH ]    = function ( Container $container ) {
			return plugins_url( 'assets', $container[ 'plugin_file' ] );
		};
		$container[ self::VERSION ] = function ( Container $container ) {
			$version = Plugin::VERSION;
			if ( file_exists( dirname( $container[ 'plugin_file' ] ) . '/build-timestamp.php' ) ) {
				include_once( dirname( $container[ 'plugin_file' ] ) . '/build-timestamp.php' );
			}
			if ( defined( 'BIGCOMMERCE_ASSETS_BUILD_TIMESTAMP' ) ) {
				$version .= '-' . BIGCOMMERCE_ASSETS_BUILD_TIMESTAMP;
			}

			return $version;
		};

		$this->admin( $container );
		$this->frontend( $container );
	}


User Contributed Notes

You must log in before being able to contribute a note or feedback.