mattrothenberg/location

此包的最新版本(1.0)没有提供许可信息。

安装数: 1,533

依赖者: 0

建议者: 0

安全: 0

星标: 5

关注者: 1

分支: 1

公开问题: 21

语言:Vue

类型:statamic-addon


README

Statamic V3的位置自动完成字段

为什么?

发布此插件的想法来源于以下博客文章。

https://dev.to/mattrothenberg/build-a-location-autocomplete-field-for-statamic-v3-49cp

在你的Statamic应用中将自定义字段类型定位在一起是一回事...为其他人构建一个插件以便他们也能使用它则是另一回事。这是我辛勤工作的成果!

安装

(无耻地借鉴自 https://github.com/riasvdv/statamic-color-swatches)

将Github仓库克隆到某处,然后将其添加到composer.json的repositories数组中。(只有在包发布之前才需要这样做。)调整url以指向克隆的目录。

"repositories": [
    {
        "type": "path",
        "url": "addons/mattrothenberg/location"
    }
]

使用Composer安装。

composer require mattrothenberg/location

发布资产

php artisan vendor:publish --provider="Mattrothenberg\Location\ServiceProvider"

添加两个环境变量,因为这个库在内部使用 Places.js 进行位置自动完成。

PLACES_APP_ID=""
PLACES_API_KEY=""