It creates a global variable. This is not recommended for a library: it is better that it just returns a table which can be used with local x = require 'x'
It has no tests
A very similar option to this by using instanceOf:
if type(x) == 'table' and type(x.instanceOf) == 'function' and x:instanceOf(MyClass) then
...
end
Because all of this, I am going to close this issue. But thanks a lot for taking the time to send a pull request!
Hello there,
There are several things incorrect on this PR.
local x = require 'x'
instanceOf
:Because all of this, I am going to close this issue. But thanks a lot for taking the time to send a pull request!