anchor.diff:  											   {error, _} ->
   												   not_found;
   											   {ok, B} ->
  -												   binary_to_list(B)
  +												   {Path, Filename ++ ".js", binary_to_list(B)}
   										   end
   								   end,
   								   Paths:list())),
   	case Sources of 
   		[] ->
   			{throw, {error, lists:flatten(io_lib:format("Cannot find module '~s'",[Filename])) }};
  -		[S|_] ->
  -			OldExports = Global:get_value("exports"),
  -			case erlv8_vm:run(VM,S) of
  -				{ok, _Result} ->
  -					Exports = Global:get_value("exports",?V8Arr([])),
  -					Global:set_value("exports",OldExports),
  -					Exports;
  -				{exception, Exception} ->
  -					{throw, Exception};
  -				{compilation_failed, Exception} ->
  -					{throw, Exception};
  -				_ ->
  +		[{Path,LoadedFilename,S}|_] ->
  +			ModuleObject = erlv8_vm:taint(VM,?V8Obj([{"exports",?V8Obj([])}])),
  +			case erlv8_vm:run(VM,?PREAMBLE ++ S ++ ?POSTAMBLE,{LoadedFilename,0,-length(?PREAMBLE)}) of
  +				{ok, F} ->
  +					F:call(This, [ModuleObject:get_value("exports"), filename:join([Path,LoadedFilename]), Path]),
  +					ModuleObject:get_value("exports");
  +				{_,_} ->
   					ignore_for_now
   			end
   	end.
  
positive.code: -module(beamjs_mod_require).
  -export([exports/1,init/1]).
  -behaviour(erlv8_module).
  -include_lib("erlv8/include/erlv8.hrl").
  
  init(_VM) ->
  	ok.
  
negative.code: 			require_file(Invocation, Filename)
  	end.
  
  require_file(#erlv8_fun_invocation{ this = This, vm = VM } = Invocation, Filename) ->
  	Global = Invocation:global(),
  	Require = Global:get_value("require"),
  	RequireObject = Require:object(),
  