npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@sap/ux-annotation-modeler-bas-ext

v1.15.4

Published

Allows you to access resources that help to define annotations in the code editor thus improving the application development by reducing effort and ensuring code consistency. The following is a subset of features that are part of this extension: code comp

Downloads

357

Readme

SAP Fiori Tools - XML Annotation Language Server

Features

The SAP Fiori Tools - XML Annotation Language Server extension provides features that assist with defining annotations in the code editor thus improving the application development productivity by reducing the effort and contributing to the code consistency and correctness.

Code Completion:

The SAP Fiori Tools - XML Annotation Language Server modeler extension provides a list of suggestions based on the project metadata and OData vocabularies. An application developer can open such a list of suggested values for annotation targets, terms, and different elements of annotation values in the annotation file and accept one of the suggestions to add or change them. This eliminates the need to look up the valid values or type complete values thus improving the development efficiency.

Micro-Snippets

The SAP Fiori Tools - XML Annotation Language Server extension provides a number of generic micro-snippets, which helps the application to accelerate the annotation definition. Bigger blocks of code get inserted and there is no need to trigger the code completion for each element or attribute. An application developer can insert repeating code patterns such as Annotations, Annotation, Record, and PropertyPath more efficiently.

Diagnostics (error-checking):

The SAP Fiori Tools - XML Annotation Language Server extension validates the annotation file against the project metadata, annotation vocabularies, and OData specification. An application developer can view the diagnostic messages and navigate to the related place in the annotation file to fix the issues.

Documentation (Vocabulary Information):

The SAP Fiori Tools - XML Annotation Language Server extension provides vocabulary information for annotation terms and their elements, such as property values, record types, etc. This information may include a description, applicability, type, etc. It also indicates if a term/element is experimental or deprecated and informs the developer if the element is mandatory. An application developer can use this information to make a better decision on how to use the annotation. The documentation scope depends on the information provided in the respective vocabulary.

Go to Definition:

Peek Definition:

i18n Support:

The SAP Fiori Tools - XML Annotation Language Server provides diagnostic warning for translatable texts which are not maintained in the i18n.properties file. An application developer can use code completion or quick fix to solve the issue.

Usage

To use the code completion:

  • Trigger the code completion by pressing CMD/Ctrl + Space. The list of suggested values is displayed. The list is filtered by already typed characters. Tip: You can filter it further by typing more characters.
  • Navigate to the desired value using up/down arrows or your mouse.
  • Accept the highlighted value using Enter key or a mouse click.

Note: If the shortcut for triggering code completion CMD + Space does not work on Mac, it is most probably assigned for the other function (e.g. opens the spotlight search). This is a known VS Code issue on Mac. The recommended solution is to change the shortcut for suggestions in VS Code. Choose File->Preferences-> Keyboard shortcuts, press edit icon and set up a new shortcut.

To use the micro-snippets:

  • Open the list of the micro-snippets available for the current position by pressing CMD/Ctrl + Space within the schema tag or its nested tags. The list of suggested micro-snippets is displayed for the specific context.

  • Navigate to the desired value by using the up/down arrows or your mouse.

  • Accept the highlighted snippet by pressing Enter or by a mouse click.

To use the diagnostics:

  • Change the annotation file. SAP UX - XML Annotation Language Server validates the annotation file against the metadata, OData specification and OData vocabularies and displays the diagnostic messages in the problems pane.
  • Click on the diagnostic message to navigate to the respective place in the document and fix the problem.

To use Go to Definition:

Place your text cursor somewhere inside the path referencing to annotation term segment or translatable string value and

  • keyboard: press F12 (in Visual Studio Code), or Ctrl + F11 (in SAP Business Application Studio)

  • mouse: right click and select Go To Definition, or.

  • keyboard and mouse: CTRL + Click (Win), command + Click (Mac)

To use Peek Definition:

Place your text cursor somewhere inside path referencing to annotation term segment or translatable string value and

  • keyboard: press Alt + F12 (Win), Option + F12 (Mac), or

  • mouse: right click and select Peek Definition

To use the documentation

  • In the code completion list, navigate to the desired value.

Prerequisites

The generated application requires the following software to be installed:

  • NodeJS Version 18.14.2 or higher
  • Local copy of OData metadata file to be present in the application folder structure.
  • manifest.json file to be present in the application folder structure and contain local URIs to the metadata and annotation file(s) in its dataSources section.
  • The annotation file must be within the webapp folder or its sub-folders

Limitations

  • Annnotations directly embedded in the metadata are not supported
  • Dynamic expressions are not supported

Support

Join the SAP Fiori Tools Community. Ask Questions, Read the Latest Blogs, Explore Content. Please assign tag: SAP Fiori tools

To log an issue with SAP Fiori Tools, please see Contact SAP Support.

Documentation

License