let me try to replicate what I tried in a simple way
explorer
- module script
- script
- module script
module script(parent)
local Module = {}
local Module2 = require(script.ModuleScript)
Module.new(Module2.new())
return Module
module script(child)
local Module = {}
local Module2 = require(script.Parent)
Module.new()
return Module
script(child)
local Module = require(script.Parent)
Module.new()
so what is my problem?
I keep getting this error (Requested module was required recursively)
this error happens whenever I have “local Module2 = require(script.Parent)” in the module script(child) script
my main question is how does this even cause recursion in the first place???