
{"id":7330,"date":"2019-06-07T09:03:49","date_gmt":"2019-06-07T00:03:49","guid":{"rendered":"https:\/\/tetraup.com\/news_topics\/archives\/7330"},"modified":"2024-09-02T15:15:18","modified_gmt":"2024-09-02T06:15:18","slug":"swift-facebook-share-guide","status":"publish","type":"post","link":"https:\/\/tetraup.com\/news_topics\/column\/swift-facebook-share-guide\/","title":{"rendered":"\u3010Swift \u958b\u767a\u3011iOS\u30a2\u30d7\u30ea\u304b\u3089facebook\u3067sns\u30b7\u30a7\u30a2\u3059\u308b\u65b9\u6cd5"},"content":{"rendered":"\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"980\" height=\"700\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/06\/\u5927\u4eba\u958b\u767a\u7cfb\u30c6\u30f3\u30d7\u30ec-980700-29.png\" alt=\"\" class=\"wp-image-9167\"\/><\/figure>\n\n\n\n<p>\u30a2\u30d7\u30ea\u3092\u958b\u767a\u306e\u969b\u306bline,twitter,facebook\u3067sns\u30b7\u30a7\u30a2\u6a5f\u80fd\u3092\u5c0e\u5165\u3059\u308b\u6a5f\u4f1a\u304c\u3042\u3063\u305f\u306e\u3067\u3001\u305d\u306e\u3068\u304d\u306e\u5de5\u7a0b\u3092\u307e\u3068\u3081\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>1 facebook for developers\u3067\u958b\u767a\u8005\u767b\u9332<\/li>\n\n\n\n<li>2 facebook for developers\u3067\u6295\u7a3f\u6a5f\u80fd\u3092\u4f7f\u3044\u305f\u3044\u30a2\u30d7\u30ea\u3092\u767b\u9332<\/li>\n\n\n\n<li>3 FacebookSDK\u3067CocoaPods\u3067\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u5c0e\u5165<\/li>\n\n\n\n<li>4 info.plist\u3067\u30e9\u30a4\u30d6\u30e9\u30ea\u306e\u8a2d\u5b9a\u3092\u3059\u308b<\/li>\n\n\n\n<li>5 \u6295\u7a3f\u306e\u5185\u5bb9\u3092\u8a2d\u5b9a<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">facebook for developers\u3067\u958b\u767a\u8005\u767b\u9332<\/h2>\n\n\n\n<p><a href=\"https:\/\/developers.facebook.com\">https:\/\/developers.facebook.com<\/a><\/p>\n\n\n\n<p>\u4e0a\u8a18\u306e\u30b5\u30a4\u30c8\u3067\u30e6\u30fc\u30b6\u30fc\u767b\u9332\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">facebook for developers\u3067\u6295\u7a3f\u6a5f\u80fd\u3092\u4f7f\u3044\u305f\u3044\u30a2\u30d7\u30ea\u3092\u767b\u9332<\/h2>\n\n\n\n<p><a href=\"https:\/\/developers.facebook.com\">https:\/\/developers.facebook.com<\/a><\/p>\n\n\n\n<p>\u307e\u305f\u3082\u4e0a\u8a18\u306e\u30b5\u30a4\u30c8\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u300c\u30de\u30a4\u30a2\u30d7\u30ea\u300d&gt;\u300c\u65b0\u3057\u3044\u30a2\u30d7\u30ea\u3092\u8ffd\u52a0\u3059\u308b\u300d\u304b\u3089\u6295\u7a3f\u6a5f\u80fd\u3092\u5c0e\u5165\u3057\u305f\u3044\u30a2\u30d7\u30ea\u3092\u767b\u9332\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3053\u3053\u3067\u767b\u9332\u3057\u305fapp id\u3068\u30a2\u30d7\u30ea\u540d\u3092info.plist\u306e\u8a2d\u5b9a\u306e\u3068\u304d\u306b\u4f7f\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">FacebookSDK\u3067CocoaPods\u3067\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u5c0e\u5165<\/h2>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"pod 'FBSDKCoreKit'\npod 'FBSDKLoginKit'\npod 'FBSDKShareKit'\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D4D4D4\">pod &#39;FBSDKCoreKit&#39;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">pod &#39;FBSDKLoginKit&#39;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">pod &#39;FBSDKShareKit&#39;<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u4e0a\u8a18\u3092Podfile\u306b\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"$ pod install\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D4D4D4\">$ pod install<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u8ffd\u52a0\u3057\u305f\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002 <\/p>\n\n\n\n<h2 class=\"wp-block-heading\">info.plist\u3067\u30e9\u30a4\u30d6\u30e9\u30ea\u306e\u8a2d\u5b9a\u3092\u3059\u308b<\/h2>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"&lt;key&gt;FacebookAppID&lt;\/key&gt;\n&lt;string&gt;{your-app-id}&lt;\/string&gt;\n&lt;key&gt;FacebookDisplayName&lt;\/key&gt;\n&lt;string&gt;{your-app-name}&lt;\/string&gt;\n&lt;key&gt;LSApplicationQueriesSchemes&lt;\/key&gt;\n&lt;array&gt;\n  &lt;string&gt;fbapi&lt;\/string&gt;\n  &lt;string&gt;fb-messenger-share-api&lt;\/string&gt;\n  &lt;string&gt;fbauth2&lt;\/string&gt;\n  &lt;string&gt;fbshareextension&lt;\/string&gt;\n&lt;\/array&gt;  \n&lt;key&gt;CFBundleURLTypes&lt;\/key&gt;\n&lt;array&gt;\n  &lt;dict&gt;\n    &lt;key&gt;CFBundleTypeRole&lt;\/key&gt;\n    &lt;string&gt;Editor&lt;\/string&gt;\n    &lt;key&gt;CFBundleURLSchemes&lt;\/key&gt;\n    &lt;array&gt;\n      &lt;string&gt;fb{your-app-id}&lt;\/string&gt;\n    &lt;\/array&gt;\n  &lt;\/dict&gt;\n&lt;\/array&gt;\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D4D4D4\">&lt;key&gt;FacebookAppID&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;string&gt;{your-app-id}&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;key&gt;FacebookDisplayName&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;string&gt;{your-app-name}&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;key&gt;LSApplicationQueriesSchemes&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;array&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;string&gt;fbapi&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;string&gt;fb-messenger-share-api&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;string&gt;fbauth2&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;string&gt;fbshareextension&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;\/array&gt;  <\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;key&gt;CFBundleURLTypes&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;array&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;dict&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    &lt;key&gt;CFBundleTypeRole&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    &lt;string&gt;Editor&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    &lt;key&gt;CFBundleURLSchemes&lt;\/key&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    &lt;array&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">      &lt;string&gt;<\/span><span style=\"color: #DCDCAA\">fb<\/span><span style=\"color: #D4D4D4\">{your-app-id}&lt;\/string&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    &lt;\/array&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  &lt;\/dict&gt;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">&lt;\/array&gt;<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u3053\u308c\u3092info.plist\u306b\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u6295\u7a3f\u306e\u5185\u5bb9\u3092\u8a2d\u5b9a<\/h2>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"import FBSDKCoreKit\nimport FBSDKShareKit\nimport FacebookShare\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> <\/span><span style=\"color: #4EC9B0\">FBSDKCoreKit<\/span><\/span>\n<span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> <\/span><span style=\"color: #4EC9B0\">FBSDKShareKit<\/span><\/span>\n<span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> <\/span><span style=\"color: #4EC9B0\">FacebookShare<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>class\u306e\u5916\u3067\u30e9\u30a4\u30d6\u30e9\u30ea\u3092import\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"func fbShare() {\n  let content = ShareLinkContent()\n  content.contentURL = NSURL(string:url) as! URL\n  content.hashtag = Hashtag(text)\n  let dialog = ShareDialog()\n  dialog.shareContent = content\n  dialog.mode = ShareDialog.Mode.native\n  dialog.show()\n}\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #569CD6\">func<\/span><span style=\"color: #D4D4D4\"> <\/span><span style=\"color: #DCDCAA\">fbShare<\/span><span style=\"color: #D4D4D4\">() {<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  <\/span><span style=\"color: #569CD6\">let<\/span><span style=\"color: #D4D4D4\"> content = <\/span><span style=\"color: #DCDCAA\">ShareLinkContent<\/span><span style=\"color: #D4D4D4\">()<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  content.<\/span><span style=\"color: #9CDCFE\">contentURL<\/span><span style=\"color: #D4D4D4\"> = <\/span><span style=\"color: #DCDCAA\">NSURL<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #DCDCAA\">string<\/span><span style=\"color: #D4D4D4\">:url) as! URL<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  content.<\/span><span style=\"color: #9CDCFE\">hashtag<\/span><span style=\"color: #D4D4D4\"> = <\/span><span style=\"color: #DCDCAA\">Hashtag<\/span><span style=\"color: #D4D4D4\">(text)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  <\/span><span style=\"color: #569CD6\">let<\/span><span style=\"color: #D4D4D4\"> dialog = <\/span><span style=\"color: #DCDCAA\">ShareDialog<\/span><span style=\"color: #D4D4D4\">()<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  dialog.<\/span><span style=\"color: #9CDCFE\">shareContent<\/span><span style=\"color: #D4D4D4\"> = content<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  dialog.<\/span><span style=\"color: #9CDCFE\">mode<\/span><span style=\"color: #D4D4D4\"> = ShareDialog.<\/span><span style=\"color: #9CDCFE\">Mode<\/span><span style=\"color: #D4D4D4\">.<\/span><span style=\"color: #9CDCFE\">native<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">  dialog.<\/span><span style=\"color: #DCDCAA\">show<\/span><span style=\"color: #D4D4D4\">()<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">}<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u30b7\u30a7\u30a2\u306e\u7a2e\u985e\u306f\u4f55\u7a2e\u985e\u304b\u3042\u308a\u307e\u3059\u304c\u3001\u4eca\u56de\u306f\u30b7\u30a7\u30a2\u30c0\u30a4\u30a2\u30ed\u30b0\u3092\u4f7f\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u307e\u3068\u3081<\/h2>\n\n\n\n<p>\u3053\u306e\u3088\u3046\u306a\u6d41\u308c\u306b\u6cbf\u3048\u3070\u3001\u7c21\u5358\u306b\u5c0e\u5165\u3067\u304d\u305f\u306e\u3067\u306f\u306a\u3044\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n\n\n\n<p>\u8a73\u3057\u3044\u3053\u3068\u306f\u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u306b\u8f09\u3063\u3066\u3044\u307e\u3059\u306e\u3067\u3001\u6c17\u306b\u306a\u308c\u3070\u305d\u3061\u3089\u3082\u53c2\u8003\u306b\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p><a href=\"https:\/\/developers.facebook.com\/docs\/swift\">https:\/\/developers.facebook.com\/docs\/swift<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30a2\u30d7\u30ea\u3092\u958b\u767a\u306e\u969b\u306bline,twitter,facebook\u3067sns\u30b7\u30a7\u30a2\u6a5f\u80fd\u3092\u5c0e\u5165\u3059\u308b\u6a5f\u4f1a\u304c\u3042\u3063\u305f\u306e\u3067\u3001\u305d\u306e\u3068\u304d\u306e\u5de5\u7a0b\u3092\u307e\u3068\u3081\u307e\u3057\u305f\u3002 facebook for developers\u3067\u958b\u767a\u8005\u767b\u9332 https:\/\/dev [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":8674,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[37],"tags":[111],"class_list":["post-7330","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-column","tag-swift"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7330","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/comments?post=7330"}],"version-history":[{"count":6,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7330\/revisions"}],"predecessor-version":[{"id":9168,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7330\/revisions\/9168"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/media\/8674"}],"wp:attachment":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/media?parent=7330"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/categories?post=7330"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/tags?post=7330"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}