3

Tried to create a map page by using the apex:map tag in a DX instance but it is an 'unknown component'.

The 'Maps & Location' menu item (normally) under Build > Customize is also missing, but I'm not sure if the two are related.

Is there a resource that lists DX limitations?

1
  • When you state, "DX Instance", do you mean a scratch org? And what Edition did you use to create the Scratch Org? DE or EE?
    – pchittum
    Commented May 5, 2017 at 10:15

1 Answer 1

5

When you create a scratch org in Salesforce DX, you can specify the edition of the org to create. In the Pilot for Spring '17, the options available are:

  • Enterprise Edition (EE)
  • Professional Edition (PE)
  • Developer Edition (DE)

Looking at two of my scratch orgs, I've created one as a DE org. I've created the other as an EE org. In my DE org, I see the same as you do: the mapping features are non-existent, and attempting to save a Visualforce page with apex:map results in a component does not exist error message from the compiler.

However, in the EE scratch org, I see the mapping features you describe, and I'm able to use and save the apex:map features without problems.

Conclusion: you need an EE scratch org.

More details:

The DX team have coined the term "org shape" to describe the form a given scratch org takes. Part of the reason for this is that scratch orgs are essentially all a kind of sandbox (and hosted in the sandbox csXX instances). But they are completely decoupled from a production org. Org shape is what let's the developer decide what kind of environment they will work in.

So how does org shape get defined in Salesforce DX? This is done with a JSON configuration file. There is documentation on how to use this file in the Salesforce DX developer guide (currently only accessible to pilot participants).

Here's the JSON file I used to setup my EE org:

{
  "Company": "My Awesome Company",
  "Country": "US",
  "LastName": "pchittum",
  "Email": "[email protected]",
  "Edition": "Enterprise",
  "OrgPreferences" : {
    "S1DesktopEnabled" : true
  }
}

The Edition attribute (as you probably rightly surmised) is the key to make your scratch org take on the shape of an EE org.

As I mentioned, documentation is only available to participants in the pilot. All details for how to access the documentation for pilot program members is in the private Chatter group that the Salesforce DX team is using to communicate with pilot participants. If you have been loaned someone's DX license, please speak to them about getting you the documentation as I suspect you will find it highly informative.

Note: This answer should be updated once Salesforce DX moves out of pilot. Any features available in pilot may behave differently once rolled into beta or production.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .