Skip to content

Remove "new" keyword? #8

@mhoeger

Description

@mhoeger

For main objects:

const app = new FunctionApp();

export const helloFunction = new AzureFunction("HelloFunction", sayHello);

vs.

const app = functionApp();

export const helloFunction = azureFunction("HelloFunction", sayHello);

For config-type settings

app.onTrigger(new HttpTrigger("api/bye", ["GET"]), goodbyeFunction);

vs.

const httpOptions: HttpOptions {
    route: "api/bye",
    method: ["GET"]
};

app.onTrigger(httpOptions, goodbyeFunction);

vs.

app.onTrigger(httpTrigger("api/bye", ["GET"]), goodbyeFunction);

Relevant issue... statefulness vs persistence: #5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions