Download the PHP package jlz/laravel-snowflake without Composer
On this page you can find all versions of the php package jlz/laravel-snowflake. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download jlz/laravel-snowflake
More information about jlz/laravel-snowflake
Files in jlz/laravel-snowflake
Download jlz/laravel-snowflake
More information about jlz/laravel-snowflake
Files in jlz/laravel-snowflake
Please rate this library. Is it a good library?
Informations about the package laravel-snowflake
Laravel Snowflake
This Laravel package to generate 64 bit identifier like the snowflake within Twitter.
Installation
Server Requirements
you will need to make sure your server meets the following requirements:
php ^7.4
JSON PHP Extension
OpenSSL PHP Extension
GMP PHP Extension
BCMath PHP Extension
laravel/framework ^7.0
Laravel Installation
Usage
Generate snowflake identifier
Analysis snowflake identifier
Usage with Eloquent
Add the MuCTS\LaravelSnowflake\Models\Traits\Snowflake
trait to your Eloquent model.
This trait make type snowflake
of primary key. Trait will automatically set $incrementing property to false.
Finally, in migrations, set the primary key to bigInteger
, unsigned
and primary
.
Configuration
If config/snowflake.php
not exist, run below:
All versions of laravel-snowflake with dependencies
PHP Build Version
Package Version
Requires
php Version
^7.4|^8.0
ext-json Version ^7.4|^8.0
ext-openssl Version ^7.4|^8.0
ext-gmp Version ^7.4|^8.0
ext-bcmath Version ^7.4|^8.0
laravel/framework Version ^7.0|^8.0
ext-json Version ^7.4|^8.0
ext-openssl Version ^7.4|^8.0
ext-gmp Version ^7.4|^8.0
ext-bcmath Version ^7.4|^8.0
laravel/framework Version ^7.0|^8.0
The package jlz/laravel-snowflake contains the following files
Loading the files please wait ....