Document redirectTo() on fixture page and page data builders
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- Nửa ngày
- Mức phù hợp với người mới
- 68/100
- Loại issue
- Tài liệu
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- markdown, php
- Lĩnh vực
- documentation
Hướng nghiên cứu
Bắt đầu từ trang fixtures trong content/4.api/, cạnh phần tài liệu hiện có về $cwa->redirect(), và đọc ví dụ redirectTo() cùng danh sách hành vi trong issue. Hãy xác nhận hành vi dựa trên PR bundle API được liên kết (#468) thay vì đoán. Hoàn thành khi trang giải thích redirectTo() khác redirect() ở điểm nào, các đích hợp lệ, các trường hợp lỗi, quy tắc --append và thay đổi đối với generate-fixtures.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
API bundle PR: https://github.com/components-web-app/api-components-bundle/pull/468 (fixes components-web-app/api-components-bundle#461)
What to document
The fixture builder has a new method on page and page data builders, redirectTo(routeName). It makes the page's own route redirect to another route, for a URL that is both a page and a redirect. A common case is a home page at / that forwards to a section.
$cwa->page('home', uiComponent: 'Primary', layout: 'main', route: '/', routeName: 'home')
->title('Home')
->redirectTo(routeName: 'graphs');
$cwa->pageData($pageData, template: 'conference', route: '/events')
->redirectTo(routeName: 'cwa-conference');
Points for the fixtures / scaffold page (content/4.api/):
- How it differs from
$cwa->redirect('/old', to: 'about'):redirect()creates a separate route that has no page, whileredirectTo()makes the page's own route redirect. - The target is a route name: any route in the same load, including a
$cwa->redirect()route, or one already in the database. An unknown name fails the load with a message naming the page or page data. - A page or page data with no route of its own (a template,
withoutRoute(), or no title and noroute:) cannot redirect, and the load fails with a message namingredirectTo(). doctrine:fixtures:load --append: the redirect is set only on a route the load creates. A page that already exists, or a route whose path is already in use, keeps the redirect it has.generate-fixturesnow writes->redirectTo(routeName: …)for a page or page data whose route redirects. Before this, it dropped the redirect and reported nothing. A target that is not part of the site is listed under "could not be reproduced".
- Ngôn ngữ chính
- Vue
- Star
- 0
- Fork
- 0
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của components-web-app/docs
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
components-web-app/docs#245 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
components-web-app/docs#243 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
components-web-app/docs#241 ·
-
documentation
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 15/100
components-web-app/docs#246 ·
-
Document the generate-fixtures asset store (fixtures.assets, $cwa->asset(), prune-fixture-assets)Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
components-web-app/docs#242 ·
Tất cả issue của components-web-app/docs
Issue tương tự
-
area: design documentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
eyalgolan/statecraft-israel#883 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:release criticality:p3 documentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
registrystack/registry-stack#2085 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
documentation good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 87/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[workshop-sync] workshop/side-quest-17-06-output-injection.md: stale add_comment.cjs line referencesĐang mởdocumentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
githubnext/gh-aw-workshop#4679 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
git-workflow task-4
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100