Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions .editorconfig

This file was deleted.

1 change: 1 addition & 0 deletions .editorconfig
38 changes: 38 additions & 0 deletions .github/workflows/analyse.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: analyse

on: ["push", "pull_request"]

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
os: [ubuntu-latest]
php: [8.3, 8.4, 8.5]
laravel: [12.*]
stability: [prefer-stable]
include:
- laravel: 12.*
testbench: 10.*

name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }}

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
coverage: none

- name: Install dependencies
run: |
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
composer update --${{ matrix.stability }} --prefer-dist --no-interaction

- name: Execute phpstan
run: php ./vendor/bin/phpstan --memory-limit=1G
32 changes: 32 additions & 0 deletions .github/workflows/duster-fix-blame.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Duster

# Commits made in here will not trigger any workflows
# Checkout Duster's documentation for a workaround

on:
push:

jobs:
duster:
runs-on: ubuntu-latest

permissions:
contents: write

steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
token: ${{ secrets.RAPIDEZ_ACTIONS_ACCOUNT_PAT }}

- name: "Duster Fix"
uses: tighten/duster-action@v2
with:
args: fix -vvv

- uses: stefanzweifel/git-auto-commit-action@v4
id: auto_commit_action
with:
commit_message: Apply fixes from Duster
commit_user_name: GitHub Action
commit_user_email: actions@github.com
11 changes: 9 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,28 @@
"prefer-stable": true,
"require": {
"php": "^8.3",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be ^8.2? According to the docs we support PHP 8.2 and above in Rapidez.

"rapidez/core": "^4.0"
"rapidez/core": "^5.0"
},
"autoload": {
"psr-4": {
"VendorName\\Skeleton\\": "src"
}
},
"config": {
"sort-packages": true
"sort-packages": true,
"allow-plugins": {
"php-http/discovery": true
}
},
"extra": {
"laravel": {
"providers": [
"VendorName\\Skeleton\\SkeletonServiceProvider"
]
}
},
"require-dev": {
"larastan/larastan": "^3.9",
"rapidez/laravel-coding-standard": "^1.0"
}
}
7 changes: 7 additions & 0 deletions phpstan.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
includes:
- ./vendor/rapidez/laravel-coding-standard/phpstan.neon

parameters:
level: 1
paths:
- src/
2 changes: 1 addition & 1 deletion resources/js/components/Example.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script>
export default {
render() {
return this.$scopedSlots.default({
return this?.$slots?.default?.({
someData: this.someData,
someMethod: this.someMethod,
someComputed: this.someComputed,
Expand Down
16 changes: 9 additions & 7 deletions resources/js/package.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
// This file will be loaded automatically after installing the package.
// See: https://github.com/rapidez/rapidez/blob/master/resources/js/app.js

// Vue.component('example', () => import('./components/Example.vue'))
// -- Or if you don't want it to be lazy loaded:
// import example from './components/Example.vue'
// Vue.component('example', example)
document.addEventListener('vue:loaded', function (event) {
const vue = event.detail.vue

document.addEventListener('vue:loaded', function () {
// You can access the main Vue instance with "window.app"
// import { defineAsyncComponent } from 'vue'
// vue.component('example', defineAsyncComponent(() => import('./components/Example.vue')))
// -- Or if you don't want it to be lazy loaded:
// import example from './components/Example.vue'
// vue.component('example', example)
// You can access the main Vue instance with "window.app" or "vue"

// window.app.$on('event-name', () => {
// window.$on('event-name', () => {
//
// });
})