@sassoftware/viyaedit - A component for data entry applications in SAS Viya
Script Tag
<script type="text/javascript" src="https://unpkg.com/@sassoftware/viyaedit></script>
The exported global is viyaedit
Packages used
-
Other key libraries (feel free to use other libraries)
Usage
Please see the repo for examples. If you are interested in writing applications to run in SAS VA (DDC and/or web content) the ViyaEditorDDC folder in the repository would be of interest.
Exported Entries
Two entries are exported.
ViyaDataEditor
The component to display either a table or a form for editing CAS or SAS datasets.
The props are:
viyaConnection - information for connecting to SAS Viya
appControl - application control information.
Please see @sassoftware/restafedit for details on these objects.
If you plan to use this component in a html page please see this link for guidance. Here is a sample:
const createRoot = ReactDOM.createRoot;
const container = document.getElementById('container1');
const root = createRoot(container);
const ViyaDataEditor = viyaedit.ViyaDataEditor;
root.render(
<ViyaDataEditor viyaConnection={LOGONPAYLOAD}
appControl ={ appControlCurrent }
/>);
An alternative is to use the method below
display
This eliminates the need to use ReactDOM directly in the html page.
Use it as follows: const props = { ViyaConnection, appControl }; viyaedit.display( props, 'name of a div');