-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
In first run search rev-manifest.json in the root of project and cache results to Nette-configurator file. | ||
|
||
**Base use** | ||
|
||
`<script type="text/javascript" src="{asset "/js/default.js"}"></script>` | ||
|
||
In production mode that makes transformation and you see in resulted html `<script type="text/javascript" src="//www.youserver.com/js/default-693eb2d376.js"></script>` | ||
|
||
In development mode used standart file name `<script type="text/javascript" src="https://localhost:9090/js/default.js"></script>` | ||
|
||
**Livereload** | ||
|
||
In latte template `{livereloadscript}` | ||
|
||
In production mode return empty string `""` | ||
|
||
In development mode return `<script type="text/javascript" src="//localhost:35729/livereload.js"></script>` | ||
|
||
**config.neon** | ||
|
||
```neon | ||
assets: | ||
manifestFile: rev-manifest.json | ||
scripthost: "https://localhost" | ||
scriptport: "9090" | ||
livereloadhost: "https://localhost" | ||
livereloadport: 35729 | ||
``` | ||
Scripthost, scriptport, livereloadhost, livereloadport may be empty. In this case used `$_SERVER['HTTP_HOST']` for hosts and `80` for port values. |