DevExtreme Vue - Project Item Templates

The views that are specific to SPA Framework-based applications can be added using one of the following DevExtreme project item templates. Use these project item templates in the Basic Application and Multi-Channel Application projects - the projects where the DevExtreme SPA Framework is used to build the application.

View

Follow these steps to add a view to your project.

  • Right-click the Views folder in a DevExtreme project and choose Add | New Item.... The Add New Item dialog will be invoked.

    Add New Item

  • Select the View template, give it a name and press Add. The .dxView, .js and .css files will be added to the project and links to them will be added in the application page (see the index.html file). The .dxView file is an HTML file that can be opened using a Designer.

    If you use an OData service in your project, the View Creation Wizard will run after you press Add in the Add New Item dialog.

    View Creation Wizard

    As you can see, you can choose to create an empty view or generate a view for an entity from your OData service. In the latter case, the wizard will help you choose an entity and view type.

    View Creation Wizard

  • Make the newly added view specific to a certain device(s) (optionally). To learn how to do this, refer to the Device Specific Markup article.

NOTE
The JavaScript functions of the Views created by the wizard are generated within the namespace specified by the project's Root namespace option. To use a custom namespace, follow the instructions given in the Set a Custom Namespace topic.

View (TypeScript)

View (Type Script) template is similar to the View item template, but the TypeScript language is used in it.