File tree 1 file changed +4
-3
lines changed
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -87,19 +87,20 @@ public function asset($path)
87
87
* it's CDN url.
88
88
*
89
89
* @param $path
90
+ * @param string $buildDir
90
91
*
91
92
* @return mixed
92
93
*
93
94
* @throws Exceptions\EmptyPathException, \InvalidArgumentException
94
95
*/
95
- public function elixir ($ path )
96
+ public function elixir ($ path, $ buildDir = ' build ' )
96
97
{
97
98
static $ manifest = null ;
98
99
if (is_null ($ manifest )) {
99
- $ manifest = json_decode (file_get_contents (public_path (' build /rev-manifest.json' )), true );
100
+ $ manifest = json_decode (file_get_contents (public_path (" $ buildDir /rev-manifest.json " )), true );
100
101
}
101
102
if (isset ($ manifest [$ path ])) {
102
- return $ this ->generateUrl (' build / ' . $ manifest [$ path ], 'public/ ' );
103
+ return $ this ->generateUrl ($ buildDir . ' / ' . $ manifest [$ path ], 'public/ ' );
103
104
}
104
105
throw new \InvalidArgumentException ("File {$ path } not defined in asset manifest. " );
105
106
}
You can’t perform that action at this time.
0 commit comments