[Merge Function] - Adjusted so it can accept bool
[JS] - Added a fade setting to the code