spatie/once
A magic memoization function
3.1.2
30M downloads/mo
#1437 most downloaded on Packagist
spatie/once
What this package is like to depend on
Last release 9 months ago
25 Nov 2025
Release timing varies
gaps range from 2 months to 2.1 years
Nearly every release is documented
notes for 18 of 19 stable releases
Nothing withdrawn
no release was ever pulled
10 years old
19 releases · first in 2016
1 release in the last 12 months
see the full history below
Release timeline
19 releases · Nov 2016 to Nov 2025Releases
latest 19-
3.1.225 Nov 2025Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 1.6.0 to 2.1.0 by @dependabot[bot] in #97
- Bump dependabot/fetch-metadata from 2.1.0 to 2.2.0 by @dependabot[bot] in #102
- Bump dependabot/fetch-metadata from 2.2.0 to 2.3.0 by @dependabot[bot] in #103
- Bump dependabot/fetch-metadata from 2.3.0 to 2.4.0 by @dependabot[bot] in #104
- Update issue template by @AlexVanderbist in #107
- Bump stefanzweifel/git-auto-commit-action from 4 to 7 by @dependabot[bot] in #108
- Bump actions/checkout from 4 to 5 by @dependabot[bot] in #106
- Added Symfony 8 support to all symfony/* packages. by @thecaliskan in #110
- Bump actions/checkout from 5 to 6 by @dependabot[bot] in #111
New Contributors
- @AlexVanderbist made their first contribution in #107
- @thecaliskan made their first contribution in #110
Full Changelog: 3.1.1...3.1.2
Release notes
Open source →What's Changed
- Bump dependabot/fetch-metadata from 1.6.0 to 2.1.0 by @dependabot[bot] in https://github.com/spatie/once/pull/97
- Bump dependabot/fetch-metadata from 2.1.0 to 2.2.0 by @dependabot[bot] in https://github.com/spatie/once/pull/102
- Bump dependabot/fetch-metadata from 2.2.0 to 2.3.0 by @dependabot[bot] in https://github.com/spatie/once/pull/103
- Bump dependabot/fetch-metadata from 2.3.0 to 2.4.0 by @dependabot[bot] in https://github.com/spatie/once/pull/104
- Update issue template by @AlexVanderbist in https://github.com/spatie/once/pull/107
- Bump stefanzweifel/git-auto-commit-action from 4 to 7 by @dependabot[bot] in https://github.com/spatie/once/pull/108
- Bump actions/checkout from 4 to 5 by @dependabot[bot] in https://github.com/spatie/once/pull/106
- Added Symfony 8 support to all symfony/* packages. by @thecaliskan in https://github.com/spatie/once/pull/110
- Bump actions/checkout from 5 to 6 by @dependabot[bot] in https://github.com/spatie/once/pull/111
New Contributors
- @AlexVanderbist made their first contribution in https://github.com/spatie/once/pull/107
- @thecaliskan made their first contribution in https://github.com/spatie/once/pull/110
Full Changelog: https://github.com/spatie/once/compare/3.1.1...3.1.2
-
3.1.127 May 2024Release notes
Open source →What's Changed
- fix spacing by @faisuc in #77
- Add Dependabot Automation by @patinthehat in #80
- Add PHP 8.2 Support by @patinthehat in #82
- Update Dependabot Automation by @patinthehat in #83
- Bump dependabot/fetch-metadata from 1.3.5 to 1.3.6 by @dependabot in #84
- Update README.md by @davidjr82 in #87
- Bump dependabot/fetch-metadata from 1.3.6 to 1.4.0 by @dependabot in #89
- Bump dependabot/fetch-metadata from 1.4.0 to 1.5.1 by @dependabot in #90
- Bump dependabot/fetch-metadata from 1.5.1 to 1.6.0 by @dependabot in #93
- Bump actions/checkout from 2 to 4 by @dependabot in #94
- Adjust pretty name of closures on PHP 8.4 by @staabm in #99
New Contributors
- @faisuc made their first contribution in #77
- @patinthehat made their first contribution in #80
- @dependabot made their first contribution in #84
- @davidjr82 made their first contribution in #87
- @staabm made their first contribution in #99
Full Changelog: 3.1.0...3.1.1
Release notes
Open source →What's Changed
- fix spacing by @faisuc in https://github.com/spatie/once/pull/77
- Add Dependabot Automation by @patinthehat in https://github.com/spatie/once/pull/80
- Add PHP 8.2 Support by @patinthehat in https://github.com/spatie/once/pull/82
- Update Dependabot Automation by @patinthehat in https://github.com/spatie/once/pull/83
- Bump dependabot/fetch-metadata from 1.3.5 to 1.3.6 by @dependabot in https://github.com/spatie/once/pull/84
- Update README.md by @davidjr82 in https://github.com/spatie/once/pull/87
- Bump dependabot/fetch-metadata from 1.3.6 to 1.4.0 by @dependabot in https://github.com/spatie/once/pull/89
- Bump dependabot/fetch-metadata from 1.4.0 to 1.5.1 by @dependabot in https://github.com/spatie/once/pull/90
- Bump dependabot/fetch-metadata from 1.5.1 to 1.6.0 by @dependabot in https://github.com/spatie/once/pull/93
- Bump actions/checkout from 2 to 4 by @dependabot in https://github.com/spatie/once/pull/94
- Adjust pretty name of closures on PHP 8.4 by @staabm in https://github.com/spatie/once/pull/99
New Contributors
- @faisuc made their first contribution in https://github.com/spatie/once/pull/77
- @patinthehat made their first contribution in https://github.com/spatie/once/pull/80
- @dependabot made their first contribution in https://github.com/spatie/once/pull/84
- @davidjr82 made their first contribution in https://github.com/spatie/once/pull/87
- @staabm made their first contribution in https://github.com/spatie/once/pull/99
Full Changelog: https://github.com/spatie/once/compare/3.1.0...3.1.1
-
3.1.021 Apr 2022 -
3.0.204 Feb 2022Release notes
Open source → -
3.0.104 Jul 2021Release notes
Open source →- fix for caching static functions of different classes with the same name (#62)
Release notes
Open source →- fix for caching static functions of different classes with the same name (#62)
-
3.0.003 Nov 2020 -
2.2.129 Oct 2020 -
2.2.018 Feb 2020 -
2.1.331 Oct 2019 -
2.1.205 Aug 2019 -
2.1.126 Jun 2019 -
2.1.019 Jun 2019Release notes
Open source →- add enabling/disable the cache
- add
flushmethod - drop support for PHP 7.1 and below
-
2.0.227 Dec 2018 -
2.0.131 Jan 2018 -
2.0.031 Jan 2018 -
1.1.024 Aug 2017 -
1.0.114 Nov 2016 -
1.0.007 Nov 2016 -
0.0.106 Nov 2016Nothing published for this version