Applaying Framework7 with Remix.js
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- react, typescript
- Lĩnh vực
- frontend, mobile-dev
Hướng nghiên cứu
Bắt đầu với app/root.tsx, đặc biệt là cấu hình Framework7 App/View và Remix Outlet, sau đó so sánh điều hướng trong app/routes/_index.tsx và app/routes/about.tsx. Tái hiện việc điều hướng bằng liên kết và xác minh rằng URL của trình duyệt được cập nhật trong khi trang अपे kiến được render thông qua các router của Remix và Framework7.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Overview
Hello Folks,
I'm trying to apply Framework7 latest version [v8.3.4] to my Remix.js app, i do all nesessry things from boath side (remix and framework7) and it's working with remix router issue
Explain the project Remix.js file
- app/root.tsx
- app/routers/_index.tsx
- app/routers/about.tsx
let's take a look how this file look like with the code:
- for full code overview take a look to this code repo: []
1- root.tsx:
import {
Links,
Meta,
Scripts,
Outlet,
ScrollRestoration,
} from "@remix-run/react";
import type { LinksFunction } from "@remix-run/node";
// Import F7 Bundle and React Plugin
import Framework7 from 'framework7/lite-bundle';
import Framework7React, { App, View } from 'framework7-react';
import AboutPage from './routes/about';
import HomePage from './routes/_index';
// Initialize Framework7 with the React plugin globally
Framework7.use(Framework7React);
// Framework7 module styles
import '../node_modules/framework7/framework7-bundle.css'
export const links: LinksFunction = () => [
{ rel: "preconnect", href: "https://fonts.googleapis.com" },
{
rel: "preconnect",
href: "https://fonts.gstatic.com",
crossOrigin: "anonymous",
},
{
rel: "stylesheet",
href: "https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",
},
];
export function Layout({ children }: { children: React.ReactNode }) {
return (
<html lang="en">
<head>
<meta charSet="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<Meta />
<Links />
</head>
<body>
{children}
<ScrollRestoration />
<Scripts />
</body>
</html>
);
}
const f7params = {
name: 'My App',
// routes
routes: [
{
path: '/',
component: HomePage,
},
{
path: '/about/',
component: AboutPage,
},
],
// ... other params
}
export default function MyApp() {
return (
<App theme="auto" {...f7params}>
{/* Main View component with "main" prop */}
<View main url="/ss">
{/* This renders nested routes via Outlet */}
<Outlet />
</View>
</App>
);
}
2- _index.tsx: (as home page with route '/')
import type { MetaFunction } from "@remix-run/node";
import { Link } from "@remix-run/react";
import { Navbar, Page } from 'framework7-react';
export const meta: MetaFunction = () => {
return [
{ title: "New Remix App" },
{ name: "description", content: "Welcome to Remix!" },
];
};
export default function Index() {
return (
// Main Framework7 App component where we pass Framework7 params
<Page>
<Navbar title="Home" />
<p>Welcome to the Home Page</p>
<Link to="/about/">About Page</Link>
</Page>
);
}
3- about.tsx: (as home page with route '/about')
import type { MetaFunction } from "@remix-run/node";
import { Link } from "@remix-run/react";
import { Page, Navbar } from 'framework7-react';
export const meta: MetaFunction = () => {
return [
{ title: "Remix App - About" },
{ name: "description", content: "Welcome to About Page!" },
];
};
const about = () => {
return (
<Page>
{/* Top Navbar */}
<Navbar title="About"></Navbar>
{/* Page Content */}
<p>Page About</p>
<Link to="/">Home</Link>
</Page>
)
}
export default about
I was wondering how to make router in Framework7 compatible with Remix
this is working but url not updated on my browser
- Ngôn ngữ chính
- JavaScript
- Star
- 18.8k
- Fork
- 3.2k
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
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 framework7io/framework7
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
framework7io/framework7#4365 · 1 bình luận ·
-
propsHistory Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
framework7io/framework7#4347 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 64/100
framework7io/framework7#4222 · 3 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
framework7io/framework7#4175 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
framework7io/framework7#3969 · 3 bình luận ·
Tất cả issue của framework7io/framework7
Issue tương tự
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 78/100
Mintplex-Labs/anything-llm#6490 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
-
[quality] workflow-scripts guard reads test:unit:coverage as skipping the unit suite, blocking #632 Đang mởagent/quality hive/hosted-available-lke648397-260827-5n31 quality testing
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
area-clientside-dartpad
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100