Skip to content

Commit

Permalink
static js require 로직 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
kimorkim committed Jun 22, 2018
1 parent eba83fc commit 904a144
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
1 change: 0 additions & 1 deletion src/renderer/src/native_controll.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var nowLocale = app.getLocale();
var options = {};
var _real_path = __dirname;
var _real_temp_path = app.getPath('userData');
sharedObject.workingPath = _real_temp_path;
var _real_temp_path_posix = _real_temp_path
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/src/require.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
const lru = require('lru-cache')({ max: 256, maxAge: 250 });
const fs = require('fs');
const _real_path = __dirname;
window._real_path = _real_path;
var origLstat = fs.lstatSync.bind(fs);
fs.lstatSync = function(p) {
let r = lru.get(p);
Expand Down
5 changes: 2 additions & 3 deletions src/renderer/src/static.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import _ from 'lodash';

var { EntryStatic } = require(path.resolve(
'src',
'renderer',
var { EntryStatic } = require(path.join(
_real_path,
'bower_components',
'entryjs',
'extern',
Expand Down

0 comments on commit 904a144

Please sign in to comment.