Wondering what’s next for npm?Check out our public roadmap! »

    This package has been deprecated

    Author message:

    No longer maintained. Use d365-cli instead

    node-webresource
    TypeScript icon, indicating that this package has built-in type declarations

    1.1.17 • Public • Published

    node-webresource

    Node module for publishing Dynamics 365 web resources, inspired by gulp-webresource

    Build NPM Semantic-Release
    Build Status npm semantic-release

    Usage

    npm install -D node-webresource

    Sign in here to grant access to your Dynamics 365 organization.

    Sample config file and usage

    For a more complete sample using webpack, see generator-xrm-webresource

    var uploadConfig = {
        tenant: "mycompany.onmicrosoft.com",
        server: "https://mycompany.crm.dynamics.com",
        webResources: [
            {
                "path": "path\\to\\file\\formscript.js",
                "name": "new_formscript.js"
            }
        ],
        solution: "MySolution"
    };
     
    // Can use username/password or client id/secret
    uploadConfig.username: "me@mycompany.onmicrosoft.com";
    uploadConfig.password: "MyPassword";
    uploadConfig.clientId: "ClientId";
    uploadConfig.clientSecret: "ClientSecret";
     
    var assets = [
        {
            path: "path\\to\\file\\formscript.js", // Should match webResources path
            content: "function onLoad() {}"
        };
    ];
     
    webResource.upload(uploadConfig, assets).then(() => {
        callback();
    }, (error) => {
        console.log(error);
        callback();
    });

    Keywords

    none

    Install

    npm i node-webresource

    DownloadsWeekly Downloads

    15

    Version

    1.1.17

    License

    MIT

    Unpacked Size

    11.1 kB

    Total Files

    5

    Last publish

    Collaborators

    • avatar