PHP code example of radnan / rdn-require-js
1. Go to this page and download the library: Download radnan/rdn-require-js library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
radnan / rdn-require-js example snippets
return array(
'modules' => array(
'RdnRequireJS',
// ...
),
);
~~~
## How to use
Create your **RequireJS** modules in your project's `public/` directory:
~~~js
// public/Bar.js
define(['./Foo'], function(Foo)
{
Foo.log('Hello World!');
});
~~~
Then, in your view templates, call the `
$this->