Skip to content

Allow supporting multiple BeforeScript and AfterScript configs #81

Open
@Zhomart

Description

@Zhomart

Currently these configs just replace the previous script, example:

	r.Get("/swagger/*", httpSwagger.Handler(
		httpSwagger.BeforeScript("console.log('before 1')"),
		httpSwagger.BeforeScript("console.log('before 2')"),
		httpSwagger.URL("http://localhost:1323/swagger/doc.json"), //The url pointing to API definition
	))

	// Only 'before 2' is printed

It makes hard to add multiple configuration scripts by forcing joing strings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions