<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Integrating Custom API Data inFeatureTable in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/integrating-custom-api-data-infeaturetable/m-p/1464103#M83218</link>
    <description>&lt;P&gt;&lt;SPAN&gt;How can I add my own data from a custom API into the Feature Table in my ArcGIS map application?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm currently developing a React application utilizing ESRI's ArcGIS API for JavaScript to display maps and interact with feature layers. Here's a simplified version of my component&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;import { Box } from '@mui/material'
import React, { useEffect } from 'react'
import { loadModules } from 'esri-loader'

 

export default function Home() {
  useEffect(() =&amp;gt; {
    loadModules(['esri/WebMap', 'esri/views/MapView','esri/layers/FeatureLayer',
    'esri/widgets/FeatureTable',], { css: true })
      .then(([WebMap, MapView,FeatureLayer, FeatureTable,]) =&amp;gt; {
        let webmap = new WebMap({
          portalItem: {
            id: '' //webmap id
          }
        })

 

        let view = new MapView({
          container: 'viewDiv',
          map: webmap
        })

 

        view.when(() =&amp;gt; {
          const featureLayer = new FeatureLayer({
            portalItem: {
              id: '' //feature layer id
            },
            outFields: ['*'],
            title: 'Customer'
          })

 

          webmap.add(featureLayer)

 

          const featureTable = new FeatureTable({
            view: view,
            layer: featureLayer,
            multiSortEnabled: true,
            editingEnabled: true,
            tableTemplate: {
              columnTemplates: [
                // Column template configurations
              ]
            },
            container: 'tableDiv'
          })

 

          view.ui.add(featureTable, 'bottom')
        })
      })
      .catch(error =&amp;gt; {
        console.error('Error loading modules:', error)
      })
  }, [])

 

  return (
&amp;lt;Box&amp;gt;
&amp;lt;Box id='viewDiv' sx={{ flex: '1', width: '100%' }}&amp;gt;&amp;lt;/Box&amp;gt;
&amp;lt;Box id='tableDiv' sx={{ flex: '1', width: '100%' }}&amp;gt;&amp;lt;/Box&amp;gt;
&amp;lt;/Box&amp;gt;
  )
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 14 May 2024 05:54:04 GMT</pubDate>
    <dc:creator>JeyaSurya</dc:creator>
    <dc:date>2024-05-14T05:54:04Z</dc:date>
    <item>
      <title>Integrating Custom API Data inFeatureTable</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/integrating-custom-api-data-infeaturetable/m-p/1464103#M83218</link>
      <description>&lt;P&gt;&lt;SPAN&gt;How can I add my own data from a custom API into the Feature Table in my ArcGIS map application?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm currently developing a React application utilizing ESRI's ArcGIS API for JavaScript to display maps and interact with feature layers. Here's a simplified version of my component&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;import { Box } from '@mui/material'
import React, { useEffect } from 'react'
import { loadModules } from 'esri-loader'

 

export default function Home() {
  useEffect(() =&amp;gt; {
    loadModules(['esri/WebMap', 'esri/views/MapView','esri/layers/FeatureLayer',
    'esri/widgets/FeatureTable',], { css: true })
      .then(([WebMap, MapView,FeatureLayer, FeatureTable,]) =&amp;gt; {
        let webmap = new WebMap({
          portalItem: {
            id: '' //webmap id
          }
        })

 

        let view = new MapView({
          container: 'viewDiv',
          map: webmap
        })

 

        view.when(() =&amp;gt; {
          const featureLayer = new FeatureLayer({
            portalItem: {
              id: '' //feature layer id
            },
            outFields: ['*'],
            title: 'Customer'
          })

 

          webmap.add(featureLayer)

 

          const featureTable = new FeatureTable({
            view: view,
            layer: featureLayer,
            multiSortEnabled: true,
            editingEnabled: true,
            tableTemplate: {
              columnTemplates: [
                // Column template configurations
              ]
            },
            container: 'tableDiv'
          })

 

          view.ui.add(featureTable, 'bottom')
        })
      })
      .catch(error =&amp;gt; {
        console.error('Error loading modules:', error)
      })
  }, [])

 

  return (
&amp;lt;Box&amp;gt;
&amp;lt;Box id='viewDiv' sx={{ flex: '1', width: '100%' }}&amp;gt;&amp;lt;/Box&amp;gt;
&amp;lt;Box id='tableDiv' sx={{ flex: '1', width: '100%' }}&amp;gt;&amp;lt;/Box&amp;gt;
&amp;lt;/Box&amp;gt;
  )
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 14 May 2024 05:54:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/integrating-custom-api-data-infeaturetable/m-p/1464103#M83218</guid>
      <dc:creator>JeyaSurya</dc:creator>
      <dc:date>2024-05-14T05:54:04Z</dc:date>
    </item>
  </channel>
</rss>

