microsoft / microsoft/azure-devops-extension-sdk

get WebConetxt not working in latest version (v3.1.2)

Open
#80 3 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
159
Forks
53
PR merge metrics
No merged PRs in 30d

Description

Hi Team,
Unable to get WebConetxt and PageConext using azure-devops-extension-sdk latest version (v3.1.2)
See below screen shot

On initialization:

image

Get webContext after initialization

image

So, it always returns following error message “Attempted to call getWebContext() before init() was complete

image

Could you please check this issue?
(OR)
Guide me how to get webContext.host.uri value without using webContext in React JS ?

Thanks in advance.

Thanks,
Vijayaraj A.

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 reproducing the reported behavior with azure-devops-extension-sdk v3.1.2 in the React initialization flow, then trace the calls to init(), getWebContext(), and getPageContext(). Done means the context methods work after initialization or the issue documents a verified way to obtain webContext.host.uri without them.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
api, developer-experience
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.