Skip to content

Remove unneeded region definitions from the /checkout page. #6997

Closed
@pynej

Description

@pynej

Preconditions

  1. Magento 2.1.1
  2. PHP 5.6
  3. Apache

Steps to reproduce

  1. In admin go to Store > Configuration > General > Allowed Countries change this list to some limited set. (We selected only United States for example.)
  2. Clear all Magento caches.
  3. Go to the Checkout page

Expected result

  1. Template/JSON code embedded in page should not have region_id definitions for all the disabled regions.

Actual result

  1. There is still 320KB of region definitions loaded on every /checkout request for all the regions we have disabled. This is a major killer of performance on the checkout page as it has to download this data every time, wont be cached, and all the non-us region data in this case will never be used as we configured the site to only allow the us region.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions