How to use the montage.Montage.getInfoForObject function in montage

To help you get started, we’ve selected a few montage examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github montagejs / montage / test / spec / core / core-require-spec.js View on Github external
function () {
            var info = Montage.getInfoForObject(objects.Proto);

            expect(info.objectName).toBe("Proto");
            expect(info.isInstance).toBeFalsy();
            expect(info.moduleId).toBe("spec/core/testobjects");
        });
        it("should describe a subclass object",
github montagejs / montage / test / spec / serialization / montage-deserializer-spec.js View on Github external
deserializer.deserializeObject().then(function (root) {
                var info = Montage.getInfoForObject(root);

                expect(Object.getPrototypeOf(root)).toBe(objects.TestobjectsV2.prototype);

                expect(info.moduleId).toBe("spec/serialization/testobjects-v2");
                expect(info.objectName).toBe("TestobjectsV2");
                expect(info.isInstance).toBe(true);
                expect(root.instance).toBeUndefined();
            }).catch(function(reason) {
                fail(reason);
github montagejs / montage / test / spec / serialization / montage-deserializer-spec.js View on Github external
deserializer.deserializeObject().then(function (root) {
                var info = Montage.getInfoForObject(root);

                expect(Object.getPrototypeOf(root)).toBe(objects.TestobjectsV2.prototype);

                expect(info.moduleId).toBe("spec/serialization/testobjects-v2");
                expect(info.objectName).toBe("TestobjectsV2");
                expect(info.isInstance).toBe(true);
                expect(root.instance).toBeUndefined();
            }).catch(function(reason) {
                fail(reason);
github montagejs / montage / test / spec / serialization / montage-deserializer-spec.js View on Github external
deserializer.deserializeObject().then(function (root) {
                var info = Montage.getInfoForObject(root);
                expect(info.moduleId).toBe("core/core");
                expect(info.isInstance).toBe(true);
                expect(root.type).toBeUndefined();
                expect(root.name).toBe("RootObjectDescriptor");
                expect(root.number).toBe(42);
                expect(root.string).toBe("a string");
            }).catch(function (reason) {
                fail(reason);
github montagejs / montage / test / spec / serialization / montage-deserializer-spec.js View on Github external
deserializer.deserializeObject().then(function (root) {
                var info = Montage.getInfoForObject(root);
                expect(info.moduleId).toBe("spec/serialization/testmjson.mjson");
                expect(info.isInstance).toBe(true);
                expect(root.type).toBeUndefined();
                expect(root.name).toBe("RootObjectDescriptor");
                expect(root.number).toBe(42);
                expect(root.string).toBe("a string");
            }).catch(function (reason) {
                fail(reason);

montage

Build your next application with a browser based platform that really gets the web.

BSD-3-Clause
Latest version published 5 years ago

Package Health Score

46 / 100
Full package analysis