> For the complete documentation index, see [llms.txt](https://docs.hackle.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hackle.io/development-guide/faq/webview-wrapper-intergration.md).

# WebView Wrapper 연동

{% hint style="danger" %}
**해당 방식으로 연동시, App 영역에서는 핵클 기능을 이용할 수 없습니다.**

* App 영역에서 핵클의 AB 테스트, 기능플래그, 원격설정 등의 기능을 사용할 수 없습니다.
* App 영역에서 사용자 식별자를 설정할 수 없습니다.
* Appsflyer 등의 MMP 솔루션을 핵클 App SDK를 통해 연동할 수 없습니다.
  {% endhint %}

{% hint style="info" %}
**WebApp(웹앱) 연동을 권장합니다.**

* WebView 상에서 자사 웹사이트를 랜더링하는 경우, 웹앱 연동을 권장하고 있습니다.
* 웹앱 연동 가이드는 [문서](/development-guide/faq/web-app-intergration.md)를 참고해주세요.
  {% endhint %}

앱에서 WebView를 이용해서 자사 웹사이트를 랜더링 하고, 앱에서 핵클의 기능을 사용하지 않는 경우 WebView Wrapper 연동을 고려할 수 있습니다.

웹에서 핵클의 기능을 사용하고, 앱에서는 핵클의 푸시만 사용할 때 WebView Wrapper 연동을 추천합니다.

WebView Wrapper 연동 시 웹에서 호출하는 핵클의 기능이 웹 SDK를 통해 동작하게 됩니다.

### 앱 SDK 연동

#### Android SDK

Android에서 WebView Wrapper 방식으로 연동을 하는 경우 앱 SDK 를 초기화 할 때 아래와 같이 `mode`를 설정해주세요.

```kotlin
val config = HackleConfig.builder()
  .mode(HackleAppMode.WEB_VIEW_WRAPPER) // <-- add WebView Wrapper mode
  .build()

Hackle.initialize(applicationContext, YOUR_APP_SDK_KEY, config) {
  // SDK ready to use.
}
```

#### iOS SDK

iOS에서 WebView Wrapper 방식으로 연동을 하는 경우 앱 SDK를 초기화 할 때 아래와 같이 `mode`를 설정해주세요.

```swift
var config = HackleConfigBuilder()
  .mode(.web_view_wrapper) // <-- add WebView Wrapper mode
  .build()

Hackle.initialize(sdkKey: sdkKey,config: config) {
  // SDK ready to use.
}

```

#### Flutter SDK

flutter를 사용하고 WebView Wrapper 방식으로 연동을 하는 경우 앱 SDK를 초기화 할 때 아래와 같이 `hackleAppMode`를 설정해주세요.

```javascript
var config = HackleConfigBuilder()
  .hackleAppMode(HackleAppMode.webViewWrapper) // <-- add WebView Wrapper mode
  .build() 

await HackleApp.initialize(sdkKey, hackleConfig: config);
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.hackle.io/development-guide/faq/webview-wrapper-intergration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
