<?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 Re: Is there a way to not have all locales in my package? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147060#M76452</link>
    <description>&lt;P&gt;Do you have a repo? I tried this out looking at the doc to let the plugin copy the assets and this work.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;new ArcGISPlugin({
  locales: ['en', 'es']
}),&lt;/LI-CODE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ReneRubalcava_0-1645635684070.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/34764iF026B15F7CBC8FAD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ReneRubalcava_0-1645635684070.png" alt="ReneRubalcava_0-1645635684070.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 23 Feb 2022 17:01:30 GMT</pubDate>
    <dc:creator>ReneRubalcava</dc:creator>
    <dc:date>2022-02-23T17:01:30Z</dc:date>
    <item>
      <title>Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1144032#M76355</link>
      <description>&lt;P&gt;Hello everybody&lt;/P&gt;&lt;P&gt;I'm using&amp;nbsp;@arcgis/core. When building the project, there are countless (all?) locales/translations loaded. Is there a way to only bundle the locales that I really want instead of all?&lt;/P&gt;&lt;P&gt;I'd be great if there was a param in `esriConfig` for example.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 15 Feb 2022 14:09:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1144032#M76355</guid>
      <dc:creator>sandrooco</dc:creator>
      <dc:date>2022-02-15T14:09:14Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1144067#M76359</link>
      <description>&lt;P&gt;This will depend on your build environment. We have a webpack-plugin that will simplify this for you.&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/Esri/arcgis-webpack-plugin" target="_blank"&gt;https://github.com/Esri/arcgis-webpack-plugin&lt;/A&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;// webpack.config.js
module.exports = {
  ...
  plugins: [
    new ArcGISPlugin({
      locales: ['en', 'es']
    })
  ]
  ...
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you're not using webpack, or don't want to use the plugin (the asset copy/filter functionality is all it really offers in most cases) you can mimic what the plugin does in your own application.&lt;/P&gt;&lt;P&gt;This is how it will filter the the locale files in the copy operation.&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/Esri/arcgis-webpack-plugin/blob/master/lib/requiredPlugins.js#L50-L73" target="_blank"&gt;https://github.com/Esri/arcgis-webpack-plugin/blob/master/lib/requiredPlugins.js#L50-L73&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Feb 2022 15:06:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1144067#M76359</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-02-15T15:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147037#M76451</link>
      <description>&lt;P&gt;Hi Rene, thanks for your help.&lt;/P&gt;&lt;P&gt;This strangely didn't work.. I was able to add the plugin and it's recognized, but the translation chunks still show up.. Do you have any other ideas?&lt;/P&gt;</description>
      <pubDate>Wed, 23 Feb 2022 16:34:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147037#M76451</guid>
      <dc:creator>sandrooco</dc:creator>
      <dc:date>2022-02-23T16:34:51Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147060#M76452</link>
      <description>&lt;P&gt;Do you have a repo? I tried this out looking at the doc to let the plugin copy the assets and this work.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;new ArcGISPlugin({
  locales: ['en', 'es']
}),&lt;/LI-CODE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ReneRubalcava_0-1645635684070.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/34764iF026B15F7CBC8FAD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ReneRubalcava_0-1645635684070.png" alt="ReneRubalcava_0-1645635684070.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Feb 2022 17:01:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147060#M76452</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-02-23T17:01:30Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147424#M76469</link>
      <description>&lt;P&gt;I don't have an example repo that I could post publicly at the moment.&lt;BR /&gt;We use Angular and injected the custom webpack bit via&amp;nbsp;&lt;SPAN&gt;@angular-builders/custom-webpack. Do you have any Angular examples?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 07:19:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147424#M76469</guid>
      <dc:creator>sandrooco</dc:creator>
      <dc:date>2022-02-24T07:19:11Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147553#M76471</link>
      <description>&lt;P&gt;I don't know Angular well enough to say,&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/180"&gt;@AndyGup&lt;/a&gt;&amp;nbsp;might have an idea.&lt;/P&gt;&lt;P&gt;Maybe you can tweak the assets copy glob to do it simpler.&lt;/P&gt;&lt;P&gt;Something like what is done in the plugin here&amp;nbsp;&lt;A href="https://github.com/Esri/arcgis-webpack-plugin/blob/master/lib/requiredPlugins.js#L67" target="_blank"&gt;https://github.com/Esri/arcgis-webpack-plugin/blob/master/lib/requiredPlugins.js#L67&lt;/A&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;  "assets": [
    {
      "glob": "**/*", // update the glob here to ignore locales
      "input": "node_modules/@arcgis/core/assets",
      "output": "/assets/"
    },
  ],&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 24 Feb 2022 15:46:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147553#M76471</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-02-24T15:46:59Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147562#M76472</link>
      <description>&lt;P&gt;Hi&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/441893"&gt;@sandrooco&lt;/a&gt; let us know what version of Angular?&lt;/P&gt;&lt;P&gt;Here's an example using Angular 11 with a custom builder and the ArcGIS webpack plugin: &lt;A href="https://github.com/andygup/angular-cli-esri-map/tree/arcgis-webpack-angular" target="_blank" rel="noopener"&gt;https://github.com/andygup/angular-cli-esri-map/tree/arcgis-webpack-angular&lt;/A&gt; . The repo is archived and it uses the AMD modules, but hopefully you can reuse some of the builder patterns to get the plugin working.&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 16:46:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1147562#M76472</guid>
      <dc:creator>AndyGup</dc:creator>
      <dc:date>2022-02-24T16:46:48Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1148031#M76481</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/180"&gt;@AndyGup&lt;/a&gt;,&amp;nbsp;thanks for your input.&lt;BR /&gt;I set up my project the same like yours, it's on Angular 13 though (shouldn't make a difference).&lt;/P&gt;&lt;P&gt;Could you please try with this and check what chunks are produced?&lt;/P&gt;&lt;PRE&gt; locales: ['en', 'es']&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 15:59:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1148031#M76481</guid>
      <dc:creator>sandrooco</dc:creator>
      <dc:date>2022-02-25T15:59:00Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1148084#M76482</link>
      <description>&lt;P&gt;Sure &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/441893"&gt;@sandrooco&lt;/a&gt;&amp;nbsp;I can take a look, it'll probably be next week. Do you have a requirement to keep the assets local? By default they'll pull from CDN, reference: &lt;A href="https://developers.arcgis.com/javascript/latest/es-modules/#working-with-assets" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/es-modules/#working-with-assets&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 17:35:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1148084#M76482</guid>
      <dc:creator>AndyGup</dc:creator>
      <dc:date>2022-02-25T17:35:53Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to not have all locales in my package?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1149495#M76544</link>
      <description>&lt;P&gt;That would be cool, thanks.&lt;BR /&gt;It's not a must to have it locally but would be nice because we could lazy load it like our other components/modules.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2022 10:16:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/is-there-a-way-to-not-have-all-locales-in-my/m-p/1149495#M76544</guid>
      <dc:creator>sandrooco</dc:creator>
      <dc:date>2022-03-02T10:16:43Z</dc:date>
    </item>
  </channel>
</rss>

