mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
fix share link
This commit is contained in:
parent
e22af25076
commit
2d63c22d1a
1 changed files with 7 additions and 12 deletions
|
|
@ -138,18 +138,13 @@ const getData = query(async (shareID) => {
|
|||
|
||||
export default function () {
|
||||
const params = useParams()
|
||||
const data = createAsync(
|
||||
async () => {
|
||||
if (!params.shareID) throw new Error("Missing shareID")
|
||||
const now = Date.now()
|
||||
const data = getData(params.shareID)
|
||||
console.log("getData", Date.now() - now)
|
||||
return data
|
||||
},
|
||||
{
|
||||
deferStream: true,
|
||||
},
|
||||
)
|
||||
const data = createAsync(async () => {
|
||||
if (!params.shareID) throw new Error("Missing shareID")
|
||||
const now = Date.now()
|
||||
const data = getData(params.shareID)
|
||||
console.log("getData", Date.now() - now)
|
||||
return data
|
||||
})
|
||||
|
||||
createEffect(() => {
|
||||
console.log(data())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue