Skip to content

Commit

Permalink
store compiled to js file
Browse files Browse the repository at this point in the history
  • Loading branch information
cbl committed Jun 24, 2020
1 parent 9555bac commit 04b60b2
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/Compiler/ScriptCompiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,17 @@ public function __construct(MinifierEngine $engine, Filesystem $files, $cachePat
$this->engine = $engine;
}

/**
* Get the path to the compiled version of a script.
*
* @param string $path
* @return string
*/
public function getCompiledPath($path)
{
return $this->cachePath . '/' . sha1($path) . '.js';
}

/**
* Add transpiler.
*
Expand Down

0 comments on commit 04b60b2

Please sign in to comment.