JS OOP create a module with IIFE

Tell us what’s happening:

Can’t get the difference between using a function that returns an object and just define the object with the two functions as property. Pretty sure there is. By the way, this code passes the test.

Your code so far

let funModule =  { 
    isCuteMixin: function(obj) {
      obj.isCute = function() {
        return true;
    singMixin: function(obj) {
      obj.sing = function() {
        console.log("Singing to an awesome tune");

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.122 Safari/537.36.

Challenge: Use an IIFE to Create a Module

Link to the challenge:

I would say the difference is in the “immediately invoked” part of
“immediately invoked function expression”. It actively returns the object, but if you only define an object, it just exists, but nothing happens with it …