vim-jp / vim-jp/vital.vim

Web.HTTP の非同期実行を行いたい

Open
#842 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Vim Script
Stars
587
Forks
64
Avg merge
2d 8h
Merged PRs (30d)
1

Description

System.AsyncProcess が入りましたので、それを利用して Web.HTTP を非同期化した Web.AsyncHTTP を追加したいです。

使用イメージ:

Web.HTTP と同じ settings が使え、 user_cb を設定することでダウンロード完了時の処理を記述できるようにする。

let s:AsyncHTTP = vital#vital#import('Web.AsyncHTTP')

function! s:user_cb(response) abort
  echomsg a:response
  " => Web.HTTP と同じ形式の辞書
endfunction

call s:AsyncHTTP.request({
      \ 'url': 'https://example.com',
      \ 'user_cb': function('s:user_cb'),
      \ })

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the existing Web.HTTP module and System.AsyncProcess to understand their APIs and how modules are structured. Add Web.AsyncHTTP with Web.HTTP-compatible settings, a request entry point, and a user_cb callback receiving the response dictionary; verify the callback runs after downloading completes.

Written by the indexing model from the issue text.

Assessment

Tech stack
vim
Domain
networking
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.